Jump to:

3447 Posts in 1032 Topics by 872 members

Template Questions

SilverStripe Forums » Template Questions » renderWith and layout

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

Page: 1
Go to End
Author Topic: 5616 Views
  • Jean-Phi
    Community Member
    12 Posts

    renderWith and layout Link to this post


    I have a file like this :

    templates/Page.ss :


    and another :



    In a controller I have an action that return :


    in the response I have 'toto' instead of :



  • Hamish
    Community Member
    712 Posts

    Re: renderWith and layout Link to this post

    That's odd. Try adding "?showtemplate=1" to the end of the URL - that will tell you what templates it's hitting.

    (btw, does your layout dir have a capital L? Don't know if it matters, but mine always have L instead if l)

  • dio5
    Community Member
    501 Posts

    Re: renderWith and layout Link to this post

    Sure you have flushed? (?flush=1)

    On the other hand try

    $this->renderWith(array('Page', 'Page'));

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.