function

htmlspecialchars . string . sncode

VERSIONlatest Convert special characters to HTML entities.

HTMLSPECIALCHARS(1e)

NAME

htmlspecialchars - Converts special characters to HTML entities.

SYNOPSIS

htmlspecialchars(str,squote)

PARAMETERS

str
The string being converted. squote Converts a single quote.

RETURN

The converted string.

EXAMPLES

Note: In the followings examples, the _ between the { should be removed to make it work.

in:  res={_{htmlspecialchars("'aa&<>xa")}}.
out: res='aa&<>xa.

in:  res={_{htmlspecialchars("'aa&<>xa",true)}}.
out: res='aa&<>xa.

AUTHOR

Written by Pusnei Sergey and Caroline Laplante, <sergey@sednove.com>