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.

Customising the CMS /

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

[MOVED]


Go to End


1273 Views

Avatar
pingu

Community Member, 75 Posts

10 March 2009 at 1:59am

Edited: 10/03/2009 2:04am

[MOVE TO TEMPLATES]

Is there a way to add items to the header of a nested template? My template structure is as follows:

themes/templates/Page.ss
themes/templates/Layout/ProductPage.ss

I want to add a javascript file reference to ProductPage.ss as it's the only template that requires the script.

I tried using Requirements in the init function of the ProductPage_Controller, however this won't work.

Would appreciate any help on this.