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.

General Questions /

General questions about getting started with SilverStripe that don't fit in any of the categories above.

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

Variables in HTMLText


Go to End


4 Posts   1263 Views

Avatar
dompie

Community Member, 88 Posts

20 January 2010 at 1:37am

Edited: 20/01/2010 1:38am

i searched the forum and docs but didn't find any satisfying answer.
I have created custom "Details" Tab where i use (among others) a Size field. Now i would like to access the value in the main content wysiwyg by writing $Size. So that the template-engine replaces $Size with the real value (e.g. XXL).

Can this be achieved somehow? I tried $Size, {$Size}, {Details.Size}, <% Details.Size %> and similar but everything failed.

Avatar
zenmonkey

Community Member, 545 Posts

20 January 2010 at 1:37pm

I'm sure I've seen a post on this before, but for the life of me I can't find it

Avatar
SilverRay

Community Member, 167 Posts

20 January 2010 at 2:26pm

Avatar
MateuszU

Community Member, 89 Posts

20 January 2010 at 2:46pm

I never knew there was a recipe for that :) If you prefer to read the code, userforms does '$Userform' replacement.