/** * Perform some actions before redirect * * FIXME: check. Action should not be an optional param * * @param string $action Current action OPTIONAL * * @return void */ protected function actionPostprocess($action = null) { parent::actionPostprocess($action); if ($action) { $this->assembleReturnURL(); } }
/** * Perform some actions before redirect * * FIXME: check. Action should not be an optional param * * @param string|null $action Performed action OPTIONAL * * @return void */ protected function actionPostprocess($action = null) { parent::actionPostprocess($action); header('Content-type: application/json'); $data = json_encode($this->data); header('Content-Length: ' . strlen($data)); echo $data; exit(0); }