Hi there,

I have some variables set using the Configure class in the
beforeFunction of the main AppController. I use for multiple things,
for example to set the title of the page.

I need a custom 404 error page, so I made a custom AppError class
containing the function error404, which overrides the build function
from the framework (see below).

The problem is that the Configure class is not working at all in
AppError.


Any suggestions?

regards,


----class sample --
class AppError extends ErrorHandler
{
        function error404()
        {
                //read the config file
                $config = Configure::read('siteConfig');

                //set it so it's available in layout & views
                $this->set('config', $config);

                .......
                ... run other code ....
                .........


                //run parent class function
                parent::__construct();
        }
}

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to