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.

We've moved the forum!

Please use forum.silverstripe.org for any new questions (announcement).
The forum archive will stick around, but will be read only.

You can also use our Slack channel or StackOverflow to ask for help.
Check out our community overview for more options to contribute.

Archive /

Our old forums are still available as a read-only archive.

Moderators: martimiz, Sean, Ed, biapar, Willr, Ingo

Tutorial - Creating Subtemplate


Go to End


2 Posts   1577 Views

Avatar
Oz

1 Post

26 October 2007 at 4:19am

Edited: 26/10/2007 9:28am

Got to give you Kiwis' your props; this is one fine CMS ....

Newby question: at the bottom of tutorial 1 there is a section on creating subtemplates: after following the directions a couple of times I found the content no longer renders: the page.ss and homepage.ss are in the template/layout directrory and $layout statement is the template/page.ss. Putting the $content stmt back in template/page.ss of course renders the content without formattng (expected)

This is a windows install .... any ideas? ....thx

Cheers
Oz

PS And there's to be no discussions about cricket, rugby or gumboots

Avatar
jananton

3 Posts

27 October 2007 at 1:06am

Hello Oz,

Hmm, a newby myself, I think you need to do a flush=1 in your cms window before looking at the result of your subclassing. (http://<yoursitename>/admin?flush=1) The new created files layout/Page.ss and layout/HomePage.ss as well as the original Page.ss need te be (re)loaded in the system before taking effect. I use a windows localhost and had the same problem in the beginning.

Greetings from overcast Amsterdam,

Jan

[using XAMPP localhost on Win XP SP2]