I'm using the latest (0.3.0) version of WSYIHTML5 for a message board. One of the features of the board is a quote post option. I've been trying to figure out how to append the quote to the text area.
I have the following jQuery as a test
So in order to update the iframe and have it format any text with HTML, I did the following..
var value = editor.getValue(); var text = '<b>some text</b>;' editor.setValue(value + text, true);
This is assuming WYSIHTML5 is instantiated under the variable 'editor'. It'll append the quote, plus format the text correctly. The boolean value is if you want the value to be run through the WYSIHTML5 parser rules.
If anyone knows a better way of doing it, I'm all ears.