ckeditor:在div标记中添加span

ckeditor:在div标记中添加span,ckeditor,html,Ckeditor,Html,我试图在div标记中添加span,但到目前为止,我尝试的代码只是一次创建一个div或span元素。 下面是我正在尝试的代码: style : new CKEDITOR.style( { // element :'div', // attributes : { 'itemscope' : '' }, element : 'span', attributes : { 'itemscope' : '', 'itemprop' : parts[ 1 ], 'name' :

我试图在div标记中添加span,但到目前为止,我尝试的代码只是一次创建一个
div
span
元素。 下面是我正在尝试的代码:

style : new CKEDITOR.style( {
    // element :'div',
    // attributes : { 'itemscope' : '' },
    element : 'span',
    attributes : { 'itemscope' : '', 'itemprop' : parts[ 1 ], 'name' :  parts[0] },
} ),

onClick : function() {
    this.style.apply( editor.document );
}