You don't need to anything like that.

You can create two layouts. One for each and select the right one in
the controller or action. For example default.ctp and helpfiles.ctp

But that is not exactly "dry" since you will duplicate all your code
except for a little div. So what I like to do is create three layouts.
One contains all the common html. Call it common.ctp or something.
Then default.ctp and helpfiles.ctp can add their own divs and then
render the common layout.

echo $this->renderLayout($content,'layoutname');

A simple mini-example:
echo $this->renderLayout('<div id="helpcolumn">'.
$content_for_layout.'</div>','common');

/Martin



On Dec 9, 11:48 am, jarek <[EMAIL PROTECTED]> wrote:
> Hello
>
> I have defined default.thtml file which have some structure (two
> columns/divs). In some cases (displaying  help) I want to change page
> structre (one div/column instead of two). How can I determiante in
> default.thtml template which action was called (without parsing data
> from $_SERVER table)?
--~--~---------~--~----~------------~-------~--~----~
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