Render problems in upgrading from 2.1.2 to 2.3.2

My custom layout file for the AdminController in in
views/layouts/admin.html.erb and has the following code:

<% content_for :secondary_nav do %>
<%= sub_navigation [:prospect_statuses, :client_statuses,
:business_statuses, :discounts, :features, :links, :user_types] %>
<% end %>
<%= render “layouts/application” %>

This works fine in Rails 2.1.2. However, in Rails 2.3.2, I get the
following error:

Showing app/views/layouts/admin.html.erb where line #4 raised:

Missing layout layouts/_application in view path app/views

Extracted source (around line #4):

1: <% content_for :secondary_nav do %>
2: <%= sub_navigation [:prospect_statuses, :client_statuses,
:business_statuses, :discounts, :features, :links, :user_types] %>
3: <% end %>
4: <%= render “layouts/application” %>

Can’t figure this out. Please help.



Found the solution here:

Changed the 4th line to:

<%= render :file => “layouts/application” %>

That solved the problem. Please disregard. Apologies for the trouble.


This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs