Jump to:

23486 Posts in 18995 Topics by 2878 members

General Questions

SilverStripe Forums » General Questions » Variables in HTMLText

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

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

Page: 1
Go to End
Author Topic: 927 Views
  • dompie
    Avatar
    Community Member
    88 Posts

    Variables in HTMLText Link to this post

    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.

  • zenmonkey
    Avatar
    Community Member
    528 Posts

    Re: Variables in HTMLText Link to this post

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

  • SilverRay
    Avatar
    Community Member
    167 Posts
  • MateuszU
    Avatar
    Community Member
    89 Posts

    Re: Variables in HTMLText Link to this post

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

    927 Views
Page: 1
Go to Top

Want to know more about the company that brought you SilverStripe? Then check out SilverStripe.com

Comments on this website? Please give feedback.