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.


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

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

Action which renders a template in the Sidebar


3 Posts   1426 Views


20 August 2008 at 2:12pm (Last edited: 20 August 2008 2:13pm), Community Member, 63 Posts


I have maybe a very simple problem but I have no Idea for the moment. I have created a action in my news page controller which shall render a template in my sidebar. I just want to populate text data in the sidebar.

Any ideas how to do that ?

Regards Thomas


20 August 2008 at 2:51pm Community Member, 1 Post

Just call the $ActionName in the


20 August 2008 at 3:00pm Community Member, 63 Posts

after another 30 minutes I have done the following and I came to the same conclusion than you

<% if GetArchive %>
<div class="sidebarBox">
<h3>Sub Menu</h3>
<% control GetArchive %>
<% end_control %>   
<% end_if %>

this is an include file to encapsulate it a little bit.

But is it possible to render the template from the controller level. Before this SilverStripe I have done mostly everything with Zend Framework and Silverstipes architecture is completely different to the Zend approach, thats why I am often a little bit confused how to do things in Silverstripe.

But anyway Silverstripe has some nice functions :)

Regards Thomas