var currentDialog = CKEDITOR.dialog.getCurrent();
currentDialog._.editor.insertHtml("<customTag myAttr='var'></customTag>");
Throws an error, TypeError: Cannot read property 'isBlock' of undefined
If I try .insertHtml("<span>hello</span>")
it works just fine.
How can I change ckeditor to allow me to specify my own custom html tags via .insertHtml()
? I'd love to just change it to be something like <span class='custom'...
or something like that, but I'm having to deal with legacy CMS articles. Using latest ckeditor. Thanks.
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…