Welcome, Guest. Register Now!
   
Mark Forums Read Mark Forums Read Mark Forums Read


Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 04-16-2008, 05:36 PM
Junior Member
 
Join Date: Apr 2008
Location: Germany, Hamburg
Posts: 11
Default Rendering current view from within layout

Hi,

a question again. Zend is rendering a layout. In my setting Zend takes the layout.phtml located in /views/scripts/layouts. How do I usally render the appropriate view? For example the /uesr/login.phtml.

Thanks in advance for your help.

Sebastian
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2 (permalink)  
Old 04-16-2008, 05:51 PM
Elemental's Avatar
Senior Member
 
Join Date: Jul 2007
Posts: 119
Default

in the layout, where ever you want the rendered view to show up:

<?php echo $this->layout()->content; ?>

The Zend Layout and View Enhancements webinar is an excellent getting started resource and of course don't forget the Reference Manual and API docs
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #3 (permalink)  
Old 04-16-2008, 07:23 PM
Junior Member
 
Join Date: Apr 2008
Location: Germany, Hamburg
Posts: 11
Default

That works. Thanks.

I'm reading through the Reference Manual pretty often, but not on the whole, I have to admit. One has to know, where to look . I tried topics about layout, rendering and so on. $this->layout()->content - so what, now I became a bit wiser . Thanks again.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT. The time now is 02:53 AM.