logo
logo

Extensions

Strings

Html Decode

Converts a string that has been HTML-encoded into a decoded string.

using Stylelabs.M.Sdk.ScriptClient;

var str = "this is a <b>string</b> in bold";

var decoded = str.HtmlDecode();

Html Encode

Converts a string into an HTML-encoded string.

using Stylelabs.M.Sdk.ScriptClient;

var str = "this is a <b>str</b> in bold";

var encoded = str.HtmlEncode();

Can we improve this article ? Provide feedback