Click or drag to resize
HTMLHelper Methods

The HTMLHelper type exposes the following members.

Methods
  NameDescription
Public methodStatic memberEncodeForHtmlAttribute
Encodes string to be used as the HTML attribute value.
Public methodStatic memberEncodeForHtmlComment
Encodes string to be used in a HTML comment.
Public methodStatic memberEnsureHtmlLineEndings
Ensures the HTML line endings (<br />) in the given text.
Public methodStatic memberEnsureURLPrefixes
Ensures that all local URLs have given prefix
Public methodStatic memberFixRTLText
Fixes RTL text. Adds special marks at the end (at the beginning) of the text if it ends (starts) with weak unicode symbol.
Public methodStatic memberFixUrl
Fixes the URL within given HTML code. The output code is HTML valid. It changes '&' to '&amp;' and backwards if needed. '?test=1&test2=2' is changed to '?test=1&amp;test2=2' '&amp;#13;' is changed to '&#13;'. '&amp;lt;' is changed to '&lt;'.
Public methodStatic memberFixXHTML
Performs the HTML code fix to become valid XHTML. Method for complete fix solution.
Public methodStatic memberGetConvertTableEnum
Converts the string representation to the ConvertTableEnum
Public methodStatic memberGetLink
Returns the HTML link element that links to a related document.
Public methodStatic memberGetSafeColorFromHtml
Returns color from HTML string color definition.
Public methodStatic memberGetUniqueControlID
Gets the unique ID for the control, if some other control has the same base ID, adds the number at the end.
Public methodStatic memberHighlightHTML
Highlight HTML.
Public methodStatic memberHTMLDecode
HTML decoding function. Returns a string converted into an HTML-decoded string.
Public methodStatic memberHTMLEncode
HTML encoding function. Returns a string converted into an HTML-encoded string. Function does not encode previously encoded HTML entity (avoiding double HTML escaping).
Public methodStatic memberHTMLEncodeLineBreaks
HTML encoding function. HTML encodes given text and replaces standard line breaks with "<br />" tag.
Public methodStatic memberHtmlToPlainText
Converts HTML to the plain text (body part).
Public methodStatic memberLimitLength
Limits the string length.
Public methodStatic memberReformatHTML
Reformats the HTML code indentation.
Public methodStatic memberRemoveComments
Remove HTML comments from given text.
Public methodStatic memberRemoveScripts
Removes the scripts from the given HTML text.
Public methodStatic memberResolveCSSClientUrls
Resolves client-relative URLs in CSS rules to absolute URLs (used with css files).
Public methodStatic memberResolveCSSUrls
Resolves application-relative URLs in CSS rules to absolute URLs (used with database style sheets).
Public methodStatic memberResolveUrls
Resolves relative URLs in the given HTML(string).
Public methodStatic memberSpanMsg
Returns span (of specified CSS class) containing message.
Public methodStatic memberStripTags(String, Boolean, String)
Remove HTML tags from text.
Public methodStatic memberStripTags(String, Boolean, Boolean, String, String, String)
Remove HTML tags from text.
Public methodStatic memberUnResolveUrls
Unresolves relative URI if used in "src=" or "href=" or "poster=" or "srcset=" or "url(".
Top
See Also