本文介绍了CLEditor动态添加文本的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我正在为正在工作的网站使用 CLEditor .我正在尝试使用jQuery将动态文本添加到textarea中.通常我会使用类似的东西:
I'm using CLEditor for a website I'm working on. I'm trying to add dynamic text to the textarea with jQuery. Usually I'll be using something like:
$('#myText').val('Here some dynamic text');
但这不适用于CLEditor.禁用CLEditor时,它可以正常工作,再次启用该文本后,该文本将消失.我尝试在网站上寻找解决方案,但找不到任何解决方案.最近有人遇到同样的问题吗?
But this just doesn't work with CLEditor. When disabling CLEditor it works fine however, enabling it again the text just disappears. I tried looking on the website for a solution, but I can't find any. Anyone had the same problem lately?
谢谢.
推荐答案
$("#input").cleditor({width:500, height:250,updateTextArea:function (){....}})
这篇关于CLEditor动态添加文本的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!