I’m a RoR noob so excuse me if this is an obvious question. I’ve
looked in all my RoR books (I have 5) and tried to find the answer in
the newsgroups but to no avail.
I have an application layout which defines the layout of the site
which has a left and right column and a content column in the middle
(3 col layout).
The left/right column contents can change depending on the current
action, so for example for my login form I do not want anything
displayed in the left but I do for the right. Once logged in I want
something in both columns, the content changes as the user navigates
My thoughts where to use partials so that the view is responsible for
what gets displayed in these columns. I would have something like this
in the application layout:
<div id="right"> <%= render (:partial => "rightcolumn") %> </div> <!-- right -->
I would then define _righcolumn.rhtml for each view.
Is this the correct approach, in those cases where I do not display
anything in either column would I have to include a blank partial???