Click or drag to resize

Utils_HtmlSanitizeHtml Method

Takes raw HTML input and cleans against a whitelist

Namespace:  MicaSystems.Utils
Assembly:  MicaSystems.Utils (in MicaSystems.Utils.dll) Version: 1.0.0.0 (1.1.0.123)
Syntax
C#
public static Html SanitizeHtml(
	string untrustedSource,
	bool throwIfInvalidTag
)

Parameters

untrustedSource
Type: SystemString
Untrusted Html source
throwIfInvalidTag
Type: SystemBoolean
If true, throws when encountering an invalid tag.

Return Value

Type: Html
Clean output
See Also