Programmatically retrieve content from WYSIHTML5 editor
问题 How do I programmatically retrieve content from a WYSIHTML5 editor? Suppose the editor is instantiated as this: var editor = new wysihtml5.Editor ( $(this.el).find('textarea').get(0), { toolbar: "toolbar", parserRules: wysihtml5ParserRules } ); i would like to get the editor's content on blur event editor.on ( "blur", function() { //what here? } ); 回答1: It's much better to use the API editor.getValue() (@dalen mentioned this in the comment above) 回答2: Here is how (using jQuery here): $(