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're retiring the forums!

The SilverStripe forums have passed their heyday. They'll stick around, but will be read only. We'd encourage you to get involved in the community via the following channels instead:

Template Questions /

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

Using variables within the CMS HTMLField

Go to End

3 Posts   1613 Views


Community Member, 18 Posts

14 January 2011 at 6:04am

Is is possible to enter a $SiteConfig variable within the text entered in the Content field of the CMS that will display that variable's value when the page is generated? I know how to use the variables in a template, but I wish to insert variables within the content itself.

Thanks for any help that is offered.



Community Member, 215 Posts

14 January 2011 at 11:49am

Hey there welcome to SilverStripe.

Yea there a few ways to do it - best option is to use a shortcode, see;

You may find that's not quite what you're after and might want to try this:

Hope that helps :)


Community Member, 18 Posts

14 January 2011 at 1:21pm

Beautiful, Howard! Works like a charm! Thank you so much!