Instance vars in layouts

Hello List,

The layouts contain the instance var @content_for_layout; is it possible
that they may also contain the instance vars from a controller similar
to
the way a controller’s views do?

cheers,

  • trav

On Jul 11, 2006, at 12:07 AM, Travis Michel wrote:

Hello List,

The layouts contain the instance var @content_for_layout; is it
possible that they may also contain the instance vars from a
controller similar to the way a controller’s views do?

cheers,

  • trav

Trav-

Yes the layout can use all the instance variables from the current

controller just like the controllers views. The way this works is
when its time to render the views, all the instance variables in the
current controller are copied into the view object to be used in the
templates.

-Ezra