Below is my application layout file
.container_12.clearfix
= render :partial => 'shared/flashes'
.grid_8
= render :partial => 'shared/search'
= yield
.grid_4
= yield(:sidebar)
It has grids, one for content and one for the sidebar. Now I am creating a login page in which I do not want to show my sidebar (only one grid. I can just create a new layout with div.grid_12 div as the only grid.
But that leaves me with two application mockups. How can I make the same application template conditional to get a sidebar?
If with the sidebar it will be the same as above, otherwise just one .grid_12, like the one below
.container_12.clearfix
= render :partial => 'shared/flashes'
.grid_12
= render :partial => 'shared/search'
= yield
source
share