0

ckeditor プラグイン「Div 編集領域」を使用して編集領域の背景色を変更するにはどうすればよいですか?

「Iframe編集エリア」プラグインを使用contentsCssして、ボディセクションを次のように変更すると、正常に動作します:

CKEDITOR.replace('Description',
        {
            uiColor: '#a7bdea',
            width: 'auto',
            height: '150',
            enterMode: CKEDITOR.ENTER_BR,
            shiftEnterMode: CKEDITOR.ENTER_P,
            contentsCss : body{ background : red}
        });

しかし、 ckeditor はcontentsCssdiv 領域の編集を無視しているようです。何か案は?

4

2 に答える 2

1

残忍だが機能している:

CKEDITOR.replace( 'editor1', {
    extraPlugins: 'divarea',
    on: {
        instanceReady: function() {
            this.editable().setStyle( 'background-color', 'red' );
        }
    }
} );
于 2013-08-02T14:21:33.087 に答える