Use $this->renderElement('element_name'); in your view for those parts that are always there and <?php echo $content_for_layout; ?> for the dynamic part.
For example: --- layout.thtml --- <html> <head> </head> <body> <!-- render header here --> <?php $this->renderElement('header'); ?> <!-- this is where your views will render --> <?php echo $content_for_layout; ?> <!-- render footer here --> <?php $this->renderElement('footer'); ?> </body> </html> You could create a method in one of your controllers, which you can call for example in beforeRender event. in that event use $this->set('content_for_header', $data); and in header.thtml you would have <?php echo $data; ?> Or something like that :) --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php -~----------~----~----~----~------~----~------~--~---