The htmlspecialchars_decode() function converts some predefined HTML entities to characters.
The htmlspecialchars_decode() function is the opposite of htmlspecialchars().
string htmlspecialchars_decode ( string $string [, int $flags = ENT_COMPAT | ENT_HTML401 ] )
The converted entities are: &, " (when ENT_NOQUOTES is not set), ' (when ENT_QUOTES is set), < and >.
<p>this -> "</p> <p>this -> "</p>
Parameter | Description |
---|---|
string | Required. Specifies the string to decode |
flags | Optional. Specifies how to handle quotes and which document type to use. |
The available quote styles are: | |
Additional flags for specifying the used doctype: | |
Returns the decoded string.