-
FEATURED COMPONENTS
First time here? Check out the FAQ!
The default contextmenu in ckeditor only past item.
I need to modify contextmenu and add some item in it.
Is there any way to do it?
Hey,
You can change it by using customConfigurationsPath :
<ckeditor customConfigurationsPath="/js/ckeditor-config.js" value="some text" />
The config file is defined as followed :
CKEDITOR.editorConfig = function(config) {
config.resize_enabled = false;
config.toolbar = 'Complex';
config.toolbar_Simple = [[ 'Bold', 'Italic', '-', 'NumberedList', 'BulletedList', '-', 'Link', 'Unlink', '-', 'About' ] ];
config.toolbar_Complex = [[ 'Bold', 'Italic', 'Underline', 'Strike', 'Subscript','Superscript', 'TextColor', 'BGColor', '-', 'Cut', 'Copy', 'Paste', 'Link', 'Unlink'],
[ 'Undo', 'Redo', '-', 'JustifyLeft', 'JustifyCenter','JustifyRight', 'JustifyBlock' ],
[ 'Table', 'SpecialChar','Styles', 'Format', 'Font', 'FontSize', 'Maximize'] ];
//config.fontSize_defaultLabel = '12'; // set font size label to 12.
//config.font_defaultLabel = 'Arial'; // set font family label to arial.
config.removePlugins = 'elementspath'; // remove bottom bar
};
With this configuration, it will use the standard complex setting.
Note : When changing the js file, clear your cache because the js file isn't refreshed otherwise.
Greetz chill.
Asked: 2015-10-01 04:03:31 +0800
Seen: 10 times
Last updated: Oct 01 '15