Displaying 3 results from an estimated 3 matches for "content_for_foo".
2006 Apr 27
0
partials and content_for
let''s say i''ve got a partial that looks like this:
<% content_for :foo do -%>
partial.id
<% end -%>
then the following works:
<%= render :partial => "partial", :collection => @collection %>
<%= @content_for_foo %>
but this does not:
<%= @content_for_foo %>
<%= render :partial => "partial", :collection => @collection %>
is there any way to get my @content_for to show up in the html output
above where the partial is rendered in the rhtml template?
thanks
--
Posted via ht...
2005 Dec 16
3
Purpose of ''yield'' in layout file in Flickr video?
During the excellent flickr video, the presenter
adds the following to the applications layout file:
<body>
<%= yield %>
</body>
What is the purpose of the ''yield'' line? I would think
there would be a content_for_layout tag there instead.
Thanks,
Don
--
Posted via http://www.ruby-forum.com/.
2006 Jul 19
4
Using Application.rhtml as layout for all controllers
I put my nav system in application layout. that way any controller
loading will have the nav system. I have one problem though - the <%=
yield %> is in the body, so how would my controllers specify other css
files?
my application layout would look like this:
<html>
<head>
title
css include
javascript include
</head>
<body>
nav system
<%=yield%>