Show / Hide Table of Contents

Class HtmlHelper

Class which provides HTML-related utility-functions.

Inheritance
Object
HtmlHelper
Namespace: SuperOffice.Util
Assembly: SoCore.dll
Syntax
public static class HtmlHelper : Object

Methods

EscapePercentageSymbols(String)

Adds escape percentage text into the first tag of html. Required for C++ parser.

Declaration
public static string EscapePercentageSymbols(string html)
Parameters
Type Name Description
String html

Html string containing percentage symbols.

Returns
Type Description
String

Html string with text that escapes percentage symbols in C++ parser.

ExtractBodyFromHtml(String, Boolean)

Class which provides HTML-related utility-functions.

Declaration
public static string ExtractBodyFromHtml(string html, bool wrap)
Parameters
Type Name Description
String html
Boolean wrap
Returns
Type Description
String

GetHTMLBodyFromPlainText(String, Boolean)

Class which provides HTML-related utility-functions.

Declaration
public static string GetHTMLBodyFromPlainText(string text, bool fragment = false)
Parameters
Type Name Description
String text
Boolean fragment
Returns
Type Description
String

GetPlainHTMLBody(String)

Retrieve plain text version of a html source

Declaration
public static string GetPlainHTMLBody(string source)
Parameters
Type Name Description
String source

HTML to convert to plain text

Returns
Type Description
String

Plain text version of the provided html

IsHtml(String)

Test if the text looks like it could be HTML. If this function returns false it means the text contains no tags.

Declaration
public static bool IsHtml(string s)
Parameters
Type Name Description
String s

Input text

Returns
Type Description
Boolean

True if the value provided contains at least 1 tag symbol

© SuperOffice. All rights reserved.
SuperOffice |  Community |  Release Notes |  Privacy |  Site feedback |  Search Docs |  About Docs |  Contribute |  Back to top