Hi,

The AppController's beforeRender() callback would be the place to do
that, so make sure you have a custom AppController ready.

lets say:

function beforeRender() {
    if (in_array($this->action, array('add', 'delete'))) {
        $this->layout = 'layout1';
    }
    parent::beforeRender();
}

On Oct 26, 7:22 am, kangur91 <[email protected]> wrote:
> Hi guys!. I want to do automatic view redirect. For example for all
> actions like "add","delete" layout will be "layout1"(not default)
> someone knows how to do that?
>
> Thanks!
--~--~---------~--~----~------------~-------~--~----~
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