bootstrap-wysihtml5
bootstrap-wysihtml5 copied to clipboard
Can't Set Value of Editor
var element = $("#example");
element.wysihtml5();
var wysihtml5 = editBody.data("wysihtml5");
var editor = wysihtml5.editor;
editor.setValue("TEST"); // Fails silently. Text is not set.
I think var wysihtml5 = editBody.data("wysihtml5"); should be var wysihtml5 = element.data("wysihtml5");
So $("#example").data("wysihtml5").editor.setValue("TEST");
What porblem if $("#Description").data('wysihtml5').editor = undefined. $("#Description").data('wysihtml5') is Wysihtml5 ? Thanks.
$("#example").data('wysihtml5').editor
always returns undefined
, so unable to set value. Is there any other method to get access to editor / set value?
Reverted back to v0.3.3 and it works fine now. Might be some problem with master
version.
Reverting to v0.3.3 solved the problem for me as well.