1320 Posts in 376 Topics by 500 members
|Go to End|
6 June 2009 at 11:31am
I'm new to SilverStripe and have gone through the tutorials and much of the documentation. I'm trying to create a new theme, and am unsure how the subtemplates work. I would like to have more than one subtemplate block in my main Page.ss file (themes/mytheme/templates/Page.ss). From the tutorial, I understand that the $Layout tag will cause SS to use the relevant subtemplate in themes/mytheme/templates/Layout/ that corresponds to the current page type. But what do I do if I have multiple areas on the page that could use a subtemplate? For instance, I have a banner area that should have different content depending on the page type. I tried creating a new folder themes/mytheme/templates/Banner/ with the hopes that putting a subtemplate there would allow me to use a $Banner tag in themes/mytheme/templates/Page.ss to display this subtemplate. But that didn't work.
Is there a way to add an additional subtemplate region like this? Or is $Layout the only subtemplate tag available?
7 June 2009 at 3:42pm
$Layout is currently the only subtemplate tag you can use.
|Go to Top|