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.

Archive /

Our old forums are still available as a read-only archive.

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

Stupid question: $Variable.XML


Go to End


3 Posts   1724 Views

Avatar
dio5

Community Member, 501 Posts

27 October 2007 at 5:59am

A few times I see template variables (like in the pagecomments) as
$Variable.XML

Now, I'm guessing this will output a xml clean string or something, could someone point me to the url in the docu where I can read upon this?

I can't seem to find it.

Avatar
Willr

Forum Moderator, 5523 Posts

27 October 2007 at 8:07pm

well I think it should be on this page - http://doc.silverstripe.com/doku.php?id=text but its probably out of date as its not. But I think from your guess its pretty spot on.

Avatar
dio5

Community Member, 501 Posts

27 October 2007 at 8:19pm

Ok,

now another question in the same line:

I'm subclassing the comment stuff but I want to allow users to use some html-tags such as <a>, <img>, ...

Is there some SS-built in method I could use, some 'bulletproof' strip_tags() thing, that gets rid of everything except the allowed tags, or should I just use strip_tags?