Documentation

editor.getText()

Retrieves the string contents of the editor. Non-string content are omitted.

Syntax

editor.getText()

Return value

Type: String

The string contents of the editor in plain text format.

Example usage

var editor1 = new RichTextEditor("#div_editor1");      
  
editor1.setHTMLCode("<p><b>Hello</b> World</p><p>Click the button below to show this text code</p>");      
  
function btnShowText() {      
    alert(editor1.getText())      
}