php - safely load HTML from user into textarea -
I am using TinyMCE 4 on a project, where I'm able to pre-populate the texture with HTML Should submit through the post (for server side error handling without deleting all of their work) I know that a Teddera works like a tag, that HTML is not parsed in the dom inside, so most site demos Shows:
But what happens when a user submits HTML in which an unmatched Is there a standard way to manage this risk? use & lt; Textarea name = "demo" & gt; & Lt ;? = $ _ POST ['Demo']? & Gt; & Lt; / Textarea & gt;
& lt; Textarea & gt; or
& lt; / Textarea & gt; tag?
htmlspecialchars ($ _ POST ['demo']) in php When outputing
Comments
Post a Comment