我知道在stackoverflow或谷歌上也有類似的問題,但目前爲止沒有任何幫助.. 我用最新穩定版本中的jquery適配器使用ckeditor。ckeditor initizialize and destroy
單擊後退和前進後,我的螢火有以下錯誤:
uncaught exception: [CKEDITOR.editor] The instance "cause" already exists
當我現在試圖摧毀編輯:
var editor=jQuery("#cause").ckeditorGet();
editor.destroy();
我有以下錯誤:
CKEditor not yet initialized, use ckeditor() with callback.
如果我嘗試逐步重現問題(除了後退/前進按鈕) 我得到的螢火一些不同的行爲
創建一個新的CKEditor
jQuery('#cause').ckeditor();
破壞編輯再次
var editor=jQuery('#cause').ckeditorGet();
editor.destroy();
嘗試重新編輯失敗(沒有任何警告或錯誤)
jQuery('#cause').ckeditor();
結果: textarea保留
預期的結果: 編輯再次出現
任何幫助,將不勝感激
嗯一些奇怪的原因,我不能再重現我的問題...... yust想要讓你知道,刪除CKEDITOR.instances.cause;固定我的問題 – nfo
相關崗位任何其他誰來到這裏http://stackoverflow.com/questions/1794219/ckeditor-instance-already-exists – Kevin
你可以在這裏查看一個現場示例https://stackoverflow.com/questions/48902441/how-to-destroy- and-reinitialize-ckeditor-again/48902974#48902974 –