HtmlUtils
TheArtOfDev.HtmlRenderer.Core.Utils
构造函数
HtmlUtils()
Init.
方法
DecodeHtml(string) : string
Decode html encoded string to regular string. Handles <, >, "&.
- str
- the string to decode
返回值: decoded string
DecodeHtmlCharByCode(string) : string
Decode html special charecters encoded using char entity code (€)
- str
- the string to decode
返回值: decoded string
DecodeHtmlCharByName(string) : string
Decode html special charecters encoded using char entity name (&#euro;)
- str
- the string to decode
返回值: decoded string
EncodeHtml(string) : string
Encode regular string into html encoded string. Handles <, >, "&.
- str
- the string to encode
返回值: encoded string
IsSingleTag(string) : bool
Is the given html tag is single tag or can have content.
- tagName
- the tag to check (must be lower case)
返回值: true - is single tag, false - otherwise
字段
_decodeOnly : Dictionary<string, char>
the html decode only pairs
_encodeDecode : KeyValuePair<string, string>[]
the html encode\decode pairs