编辑ckeditor config.js没有任何影响

cod*_*nja 7 javascript jquery ckeditor

我更改了我的CKeditor config.js文件,以包含所有可能的按钮:

CKEDITOR.editorConfig = function( config ) {
    config.toolbarGroups = [
        { name: 'document', groups: [ 'mode', 'document', 'doctools' ] },
        { name: 'clipboard', groups: [ 'clipboard', 'undo' ] },
        { name: 'editing', groups: [ 'find', 'selection', 'spellchecker', 'editing' ] },
        { name: 'forms', groups: [ 'forms' ] },
        '/',
        { name: 'basicstyles', groups: [ 'basicstyles', 'cleanup' ] },
        { name: 'paragraph', groups: [ 'list', 'indent', 'blocks', 'align', 'bidi', 'paragraph' ] },
        { name: 'links', groups: [ 'links' ] },
        { name: 'insert', groups: [ 'insert' ] },
        '/',
        { name: 'styles', groups: [ 'styles' ] },
        { name: 'colors', groups: [ 'colors' ] },
        { name: 'tools', groups: [ 'tools' ] },
        { name: 'others', groups: [ 'others' ] },
        { name: 'about', groups: [ 'about' ] }
    ];
};
Run Code Online (Sandbox Code Playgroud)

此配置是使用CKeditor 配置生成器工具生成的.

将更改部署到我的服务器并使用Chrome中的隐身模式刷新页面后,没有更改任何按钮.

如果我直接在我的代码中添加此代码,admin.master则新按钮会显示.

<script>
    jQuery(function() {
        CKEDITOR.config.extraPlugins = 'justify';
    });
</script>
Run Code Online (Sandbox Code Playgroud)

我可能根本不使用它config.js吗?

小智 0

我也遇到了同样的问题,我不得不删除浏览器数据。在 Chrome 中,您可以选择时间范围。起初,我选择了最后一个小时,但这不起作用。然后我选择了所有时间,结果就这样了。