public function responseAjax()
    {
        if (!$this->isAjax()) {
            $this->response->outputError403();
        }

        $action = $this->getPosted('action');

        if (empty($action)) {
            $this->outputJson(array('error' => $this->text('Unknown action')));
        }

        $this->outputJson(call_user_func(array($this, $action)));
    }
public function responseAjax()
    {
        if (!$this->isAjax()) {
            $this->response->outputError403();
        }

        $action = $this->getPosted('action');

        if (empty($action)) {
            $this->outputJson(array('error' => $this->text('Unknown action')));
        }

        $this->outputJson(call_user_func(array($this, $action)));
    }
public function responseAjax ( ) { if ( ! $ this -> isAjax ( ) ) { $ this -> response -> outputError403 ( ) ; } $ action = $ this -> getPosted ( 'action' ) ; if ( empty ( $ action ) ) { $ this -> outputJson ( array ( 'error' => $ this -> text ( 'Unknown action' ) ) ) ; } $ this -> outputJson ( call_user_func ( array ( $ this , $ action ) ) ) ; }
Page callback
Entry point for all AJAX requests
Page callback Entry point for all AJAX requests