简体   繁体   English

Internet Explorer版本8中的CKEditor错误

[英]CKEditor error in internet explorer version8

I am using CKEditor version 4.2 full version.For uploading image in ckeditor i have used the following code on document ready: 我正在使用CKEditor 4.2完整版。为了在ckeditor中上传图像,我在准备好的文档上使用了以下代码:

CKEDITOR.replace('editor1', {                
       filebrowserUploadUrl: '/SendNewsletter/UploadImage'(This is Controller)
 });
 <html>
 <textarea class="ckeditor" id="editor1" cols="10" rows="10"></textarea><br />
        <input type="button" value="Send Bulk Msg" id="Compose" />
 </html>

It is absolutely fine in firefox and chrome.But in IE8 i'm getting the following error: "The editor instance "'+b.getEditor().name+'" is already attached to the provided element" 在firefox和chrome中绝对可以。但是在IE8中,出现以下错误:“编辑器实例“'+ b.getEditor()。name +'”已附加到提供的元素上“

when i pass the exception on the program being debugged,then upload button is invisible in the editor.and also the submit buton is not working. 当我在正在调试的程序上传递异常时,然后在编辑器中看不到上传按钮。而且提交按钮也无法正常工作。

Firefox and Chrome should give you exactly the same error, but as they don't show javascript errors so obviously you're not aware of it. Firefox和Chrome应该会给您完全相同的错误,但是由于它们不显示javascript错误,因此显然您不知道该错误。

Your textarea has a class of "ckeditor", so it's automatically used by CKEditor and then it throws you the error because it's already been replaced. 您的textarea具有“ ckeditor”类,因此CKEditor会自动使用它,然后由于已被替换而引发错误。

Remove that class and your problem will be gone. 删除该类,您的问题将消失。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM