API

HtmlEncoder.Default.Encode

Encodes a string for HTML context; it is not a general-purpose sanitizer.

Formal Syntax & Structure

csharp syntaxcsharp
HtmlEncoder.Default.Encode(title)

Working Example

Example Snippetcsharp
// Documentary fragment; see mapped lesson for context.HtmlEncoder.Default.Encode(title)
C# & .NET Reference