Show / Hide Table of Contents

Class HttpUtility

Provides methods for encoding and decoding HTML and URL strings.

Inheritance
System.Object
HttpUtility
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: System.Windows.Browser
Assembly: OpenSilver.Browser.dll
Syntax
public static class HttpUtility

Methods

| Improve this Doc View Source

HtmlDecode(String)

Converts a string that has been HTML-encoded (for HTTP transmission) into a decoded string.

Declaration
public static string HtmlDecode(string html)
Parameters
Type Name Description
System.String html

An HTML-encoded string to decode.

Returns
Type Description
System.String

A decoded string.

| Improve this Doc View Source

HtmlEncode(String)

Converts a text string into an HTML-encoded string.

Declaration
public static string HtmlEncode(string html)
Parameters
Type Name Description
System.String html

The text to HTML-encode.

Returns
Type Description
System.String

An HTML-encoded string.

| Improve this Doc View Source

UrlDecode(String)

Converts a string that has been encoded for transmission in a URL into a decoded string.

Declaration
public static string UrlDecode(string url)
Parameters
Type Name Description
System.String url

A URL-encoded string to decode.

Returns
Type Description
System.String

A decoded string.

| Improve this Doc View Source

UrlEncode(String)

Converts a text string into a URL-encoded string.

Declaration
public static string UrlEncode(string url)
Parameters
Type Name Description
System.String url

The text to URL-encode.

Returns
Type Description
System.String

A URL-encoded string.

  • Improve this Doc
  • View Source