If you put your partial (say "_parto.rhtml'') in your layouts
folder
then you can reference it like this:
render (:partial => "/layouts/parto")
Hope this helps
Eifion
On 19 Meh 2006, at 14:17, Dave Verwer wrote:
> Hi
>
> I am using a ''master'' layout in my project by putting
"layout
> ''main''" in
> my application controller so that the same layout is applied to every
> controller and I would like to use partials in the layout file
> (obeying
> DRY, of course!) but if I render a partial in the layout then whenever
> the layout is rendered by a controller the layout looks for the
> partial
> in the executing controller folder and obviously I want it to be
> generic
> across controllers.
>
> I have tried putting the partial in the layout folder hoping that it
> would check there first (it seemed logical) before checking the
> controller folder.
>
> Is there a place I can put partials where they will always be found?
>
> Thanks
> Dave
>
> --
> Posted via http://www.ruby-forum.com/.
> _______________________________________________
> Rails mailing list
> Rails@lists.rubyonrails.org
> http://lists.rubyonrails.org/mailman/listinfo/rails