【发布时间】:2010-06-06 01:09:03
【问题描述】:
有了CKEDITOR,当我使用JS获取文本编辑器的内容时,我又回来了:
<p>\u000a\u0009 ad adad ad asd</p>\u000a
什么时候我应该得到:
<p>ad adad ad asd</p>
知道这里发生了什么吗?
唯一可能的原因是我在加载时动态创建了文本区域,并使用一个类来查找编辑器:
$('.guideItem-textarea').each(function(index, value){
// ID of the textarea
var targeteditor = $(this).attr('id');
var targeteditorID = $(this).attr('id').replace('noteguide','');
// Contents in the editor
textareacontents = CKEDITOR.instances[targeteditor].getData();
});
有什么想法吗?
【问题讨论】:
标签: ckeditor