Поделиться через


WriteHtmlEncodeWithQuote Method

The WriteHtmlEncodeWithQuote method of the SPEncode class encodes the specified string so that characters in embedded HTML tags are displayed as text in the browser, and writes the string in quotation marks to the HTTP output content stream.

Parameters

response   The System.HttpResponse object for the current HTTP request.

str   The string to encode.

quoteChar   A System.Char that specifies the character to use for quotation marks.

Remarks

The WriteHtmlEncodeWithQuote method converts characters that could be confused with HTML tags to entities. For example, "<" is converted to "&lt;".

This method replaces multiple spaces in the string with a single space.

Requirements

Platforms: Microsoft Windows Server 2003

Security: Code Access Security