SP.Utilities.HttpUtility.escapeXmlText(toescape) Method
Applies to: SharePoint Foundation 2010
In this article
Return Value
Remarks
Applies To
Replaces all of the significant HTML characters in specified text with the appropriate HTML entity code.
var value = SP.Utilities.HttpUtility.escapeXmlText(toescape);
Parameters
toescape
Type: string
The specified text to escape.
Return Value
Type: string
The escaped text.
Remarks
The following list shows all of the significant HTML characters that are escaped:
Escape character |
HTML entity code |
---|---|
" |
" |
' |
' |
& |
& |
< |
< |
> |
> |
Applies To
SP.Utilities.HttpUtility Class