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.

Widgets /

Discuss SilverStripe Widgets.

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

How do you render the widget differently depending on the page class?


Go to End


1536 Views

Avatar
otherjohn

Community Member, 125 Posts

1 October 2011 at 3:29am

Edited: 01/10/2011 3:29am

Hi all,
I would like to apply a different template to the widget(s) on that page depending on what page classname they are on. So if the page ClassName is HomePage then render one way but if its BlogHolder or Page, render another.

How can I do this?