Error Control in Yii
{Application}
default action is r=site/error, do anything you want in it. jump to an address, render a new file ....
{Modules}
Open ModuleName+Module.php file, then add something input init() method, just as what you think, overwrite the default set when this module run.
Yii::app()->setComponents(array( 'errorHandler'=>array( 'class'=>'CErrorHandler', 'errorAction'=>'oldweeklyadmin/default/error', ),
{Boy Say}
thx for troyfan's code.
Leave Comment