繁体   English   中英

ckeditor中的插件激活

[英]plugin activation in ckeditor

我已经下载了colorbutton插件。 并将插件放入ckditor插件文件夹。 在config.js中,我已经激活了我的插件。 但是,当我将激活代码放入confiq.js文件中时,整个ckeditor都会从页面中消失。 当我删除此“ config.extraPlugins ='colorbutton';” 从代码ckeditor出现在isert时,它会消失,而我需要ckeditor中的text coloroption。

紧随其后的是config.js

CKEDITOR.editorConfig = function( config ) {

// Define changes to default configuration here.
// For the complete reference:
// http://docs.ckeditor.com/#!/api/CKEDITOR.config

// The toolbar groups arrangement, optimized for two toolbar rows.
config.toolbarGroups = [
    { name: 'clipboard',   groups: [ 'clipboard', 'undo' ] },
    { name: 'editing',     groups: [ 'find', 'selection', 'spellchecker' ] },
    { name: 'links' },
    { name: 'insert' },
    { name: 'forms' },
    { name: 'tools' },
    { name: 'document',    groups: [ 'mode', 'document', 'doctools' ] },
    { name: 'others' },
    '/',
    { name: 'basicstyles', groups: [ 'basicstyles', 'cleanup' ] },
    { name: 'paragraph',   groups: [ 'list', 'indent', 'blocks', 'align' ] },
    { name: 'styles' },
    { name: 'colors' },
    { name: 'about' }
];

// Remove some buttons, provided by the standard plugins, which we don't
// need to have in the Standard(s) toolbar.
config.removeButtons = 'Underline,Subscript,Superscript';

// Se the most common block elements.
config.format_tags = 'p;h1;h2;h3;pre';
// Make dialogs simpler.
config.removeDialogTabs = 'image:advanced;link:advanced';

var path12 = CKEDITOR.basePath; config.filebrowserBrowseUrl = path12 +'image / browse.php?type = files'; config.filebrowserImageBrowseUrl = path12 +'image / browse.php?type = images'; config.filebrowserFlashBrowseUrl = path12 +'image / browse.php?type = flash'; config.filebrowserUploadUrl = path12 +'image / upload.php?type = files'; config.filebrowserImageUploadUrl = path12 +'image / upload.php?type = images'; config.filebrowserFlashUploadUrl = path12 +'image / upload.php?type = flash'; config.extraPlugins ='colorbutton'; };

我假设您没有正确的文件夹结构。 您是否将插件放置在正确的文件夹及其内容中?

plugin_sdk_sample_1

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM