Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

General Questions /

General questions about getting started with SilverStripe that don't fit in any of the categories above.

Moderators: martimiz, Sean, biapar, Willr, Ingo, swaiba, simon_w

Modules and Themes...


Reply


529 Views

Avatar
njprrogers

Community Member, 23 Posts

12 April 2011 at 3:39am

Hi,

I've stuck some code from extending my site into a module for neatness / implementation reasons.

This site has a custom built theme.

I'm introducing about 15 new page types in this development. I'm trying to avoid creating a .ss page in the module/template folder for each one as the structure is the same for each one i.e.
Header
Layout
Footer

The page.ss heirarchy is very handy so you don't have to repeat yourself within mysite/code.

Is there a way to replicate this functionality within a module? I understand why my theme is not picking up a page.ss in my module folder from the way that the templating heirarchy works i.e.
1)mysite (or other name given to site folder)
2)themes
3)module (eg blog)

So, a default template .ss in a module with multiple layouts just like in mysite... possible?

Thanks in advance!

Nick