789 Posts in 336 Topics by 301 members
|Go to End|
26 May 2009 at 11:39pm
I want to write a widget, which I can set different includes into my Sidebar. The php file of the widget works without any errors, but SilverStripe doesn't interpet <% include .... %>. I know, why this doesn't work. Maybe is there a chance to have access the global variable like CurrentMember in my control command.
<% control IncludeIn %>
<% include $Include %>
<% end_control %>
3 June 2009 at 11:42am Last edited: 3 June 2009 11:44am
Write a function in your widget to output the html/text that you want.
Call that function from within the control loop.
Look at the HTML widget, it may do what you want. This forum contains instructions on getting it to work.
|Go to Top|