Jump to:

3439 Posts in 1028 Topics by 869 members

Template Questions

SilverStripe Forums » Template Questions » <filename>.ss does not work

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

Page: 1
Go to End
Author Topic: 432 Views
  • phokki
    Community Member
    14 Posts

    <filename>.ss does not work Link to this post

    Hello, im quite new to SilverStripe,

    I've got a Order page on the website and in the CMS i've got a page with the page type Order.
    Now i want to edit the Order page, so i made OrderPage.ss to make the layout right.

    <div id="page">
    <div id="small_logo">
    <img title="Logo IJzerleeuw" alt="Logo IJzerleeuw" src="$ThemeDir/images/ijzerleew_logo_transparant_small.png" />
    <div id="page_text">

    But this page isnt showing anything..
    The Page.ss is showing instead of OrderPage.ss

    I did dev/build?flush=1 but it isnt working.

    Anyone got an idea? Thanks already!

  • Tim Snadden
    Community Member
    32 Posts

    Re: <filename>.ss does not work Link to this post

    You say that the page type is Order but your template is called OrderPage. Make sure that the names are all aligned as this is how Silverstripe automagically selects the correct template.

    class OrderPage extends Page {

    class OrderPage_Controller extends Page_Controller {


    In the CMS make sure that in the Behavior tab you have set the page to be an OrderPage.

    Also, it looks like your template is not a full HTML document but is a fragment. In this case you want to store it in templates/Layout/ and insert $Layout into your main template to insert your Order Page layout at that point (rather than $Content).

Page: 1
Go to Top

Want to know more about the company that brought you SilverStripe? Then check out SilverStripe.com

Comments on this website? Please give feedback.