Error.php
462 Bytes
<?php
/**
* @name ErrorController
* @desc 错误控制器, 在发生未捕获的异常时刻被调用
* @see http://www.php.net/manual/en/yaf-dispatcher.catchexception.php
* @author liuziyang
*/
use Action\AbstractAction;
class ErrorController extends AbstractAction
{
public function indexAction($exception)
{
header('HTTP/1.1 404 Not Found');
header('Status: 404 Not Found');
$this->_view->render('error');
}
}