Monday, April 29, 2013

Changing default error layout in CakePHP

app/Controller/ErrorsController.php

class ErrorsController extends AppController {
    public $name = 'Errors';

    public function beforeFilter() {
        parent::beforeFilter();
        $this->Auth->allow('error404');
    }

    public function error404() {
        //$this->layout = 'default';
    
}   


Refer -
http://stackoverflow.com/questions/9620363/cakephp-2-0-how-to-make-custom-error-pages

No comments:

Post a Comment