Examples
editor.getHTMLCode()
This method is used for retrieving the content of RichTextEditor as HTML.
Syntax
editor.getHTMLCode()
Return value
Type: String
The string contents of the editor with formatting data.
Output filters are used to strip-out internal content created during the editing process (such as allowScriptCode, tagAllowList, tagBlockList...).
Example:
var editor1 = new RichTextEditor("#div_editor1");
editor1.setHTMLCode("<p><b>Hello</b> World</p><p>Click the button below to show this HTML code</p>");
function btnShowHTMLCode() {
alert(editor1.getHTMLCode())
}