Strings are shown with quotation marks

Dear all,

I just recently realized that using a stach {{variable}} will render “value of variable” (including the quotation marks) in html.

Is there a way to turn this off? From the database I fetch html stored in the variable and with the quotation marks in place, all html tags are visible to the end user. The desired text formatting is not taking place of course.



Stache does not do that. Does your data have the quotation marks.

Hi Justin,

you are right. Chrome puts quotes around text nodes.
So it looks like the content of the variable is rendered as text node.
E.g. < is written as &lt;

Any way to prevent this?
Probably not so I can’t put html into a variable and expect it to be rendered properly?



If you want to output unescaped markup, use 3 curly braces: {{{variable}}}

Ha, thanks a lot. I knew it would be something simple :smiley: