I want to create a custom self closing node in CKeditor, is there a way to do this? My code so far:
this.videoElement = editor.document.createElement('cfwvideo');
this.videoElement.setAttribute('src', videoSource);
editor.insertEl开发者_如何学Pythonement(this.videoElement);
Ah found it, you'll have to add the control name to the $empty list in CKEDITOR.dtd like this: CKEDITOR.dtd.$empty['cfwvideo'] = 1;
精彩评论