Let's say we have a layout as /app/views/layout/mylayout.thtml. We
want to display different content (besides the content of invoked
action) according to current controller/action with the very same
layout. For example if post/add action is invoked, a component named
'instruction' is rendered; while news/index action is invoked, another
component named 'rss_feeder' is rendered to replace 'instruction'.

I know that this can be done by having different layouts just for
different use. But most of the content will then be very similar. It's
not DRY and difficult to manage if there is a global change to these
layouts. So I think it's better to pass a variable to the same layout,
so that the layout knows what content to display or requestAction to
invoke.

I am using Cake 1.1.x.x by the way.

Do you guys have a solution or a better way to do this? Thanks in
advance.


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Cake 
PHP" 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