1

So I have some user generated content areas of my site. I want them to be able to use html for markup purposes, but I don't want them to be able to execute any arbitrary javascript.

From my understanding raw() will just output everything, html, javascript, and all right into the webpage.

Is there a method that will allow raw rendering of html but not allow rendering of javascript?

1
  • You're looking for an HTML sanitizer. Commented Aug 10, 2011 at 6:28

1 Answer 1

1

Have a look at sanitize.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.