Bootstrap Wysihtml5 Set Value Not Working


Answer :

You should be able to achieve the same using below

$("#<%=txtDescrizioneBreveCategoria.ClientID%>").wysihtml5(); window.describeEditor = window.editor; 

And then later you should can use

describeEditor.setValue(c.DescrizioneBreve, true) 

or use

editorDescrizioneBreve.data("wysihtml5").editor.setValue(c.DescrizioneBreve, true); 

Where editorDescrizioneBreve is the object returned by $("#<%=txtDescrizioneBreveCategoria.ClientID%>").wysihtml5()

PS: Solution based on https://github.com/jhollingworth/bootstrap-wysihtml5/issues/52


For me, this worked:

$('.wysihtml5-sandbox').contents().find('body').html(descr) 

I have only one Wysihtml5 on my page, with multiple, you need to use more precise selector.


Comments

Popular posts from this blog

Chemistry - Bond Angles In NH3 And NCl3

Are Regular VACUUM ANALYZE Still Recommended Under 9.1?

Change The Font Size Of Visual Studio Solution Explorer