Fix: kill instance if exist
This commit is contained in:
parent
8369e7fbe2
commit
8ccbe4c7dd
@ -164,6 +164,9 @@ class DolEditor
|
|||||||
|
|
||||||
$out.= '<script type="text/javascript">
|
$out.= '<script type="text/javascript">
|
||||||
jQuery(document).ready(function () {
|
jQuery(document).ready(function () {
|
||||||
|
if (CKEDITOR.instances[\''.$this->htmlname.'\']) {
|
||||||
|
CKEDITOR.remove(CKEDITOR.instances[\''.$this->htmlname.'\']);
|
||||||
|
}
|
||||||
CKEDITOR.replace(\''.$this->htmlname.'\',
|
CKEDITOR.replace(\''.$this->htmlname.'\',
|
||||||
{
|
{
|
||||||
customConfig : \''.dol_buildpath('/theme/'.$conf->theme.'/ckeditor/config.js',1).'\',
|
customConfig : \''.dol_buildpath('/theme/'.$conf->theme.'/ckeditor/config.js',1).'\',
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user