pyrocms/pyrocms — Issue #1047: Docs re page layout
Author: steward
Created: 2011-12-29 19:29:53+00:00
State: open

RE
Different Layouts
PyroCMS will check for a layout file that has the same name as a module. So if you want the blog module to have a sidebar with some widgets, or a totally different design, then you can create addons/themes//views/layouts/blog.html. It will automatically be recognized and used instead of the default.html file.

NOTE:
If you create a layout called "home.html", the pages module uses it for the index page. Even though there is a "default". This falls out of the design but needs special mention, since it's an obvious choice for a layout file, but there will be no config or database settings to help trace why your home page layout is or is not getting picked up. We expect the module name to be reserved for special layouts, but "home" is a special case of "pages"...