PHP Class Backend\Core\Engine\Base\AjaxAction

Inheritance: extends Object
显示文件 Open project: forkcms/forkcms Class Usage Examples

Public Methods

Method Description
execute ( ) : Response Execute the action
getContent ( ) : Response Since the display action in the backend is rather complicated and we want to make this work with our Kernel, I've added this getContent method to extract the output from the actual displaying.
output ( integer $statusCode, mixed $data = null, string $message = null ) Output an answer to the browser

Method Details

execute() public method

Execute the action
public execute ( ) : Response
return Symfony\Component\HttpFoundation\Response

getContent() public method

With this function we'll be able to get the content and return it as a Symfony output object.
public getContent ( ) : Response
return Symfony\Component\HttpFoundation\Response

output() public method

Output an answer to the browser
public output ( integer $statusCode, mixed $data = null, string $message = null )
$statusCode integer The status code for the response, use the available constants: self::OK, self::BAD_REQUEST, self::FORBIDDEN, self::ERROR
$data mixed The data to output.
$message string The text-message to send.