Closed aslamdoctor closed 11 years ago
@aslamdoctor
See the example below, is the CKEditor's default configuration. By default, the CKEditor put new buttons in the others category.
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', 'bidi' ] },
{ name: 'styles' },
{ name: 'colors' },
{ name: 'about' }
];
So, moving the others category after the about category, will put the button in the last position.
config.toolbarGroups = [
...
{ name: 'about' },
{ name: 'others' }
];
Actually, the button is placed in 'insert', not 'others'. It would be cool if we could add the button wherever we want. As it is right now, I can't control the buttons contained in insert, if I want to include the youtube button. I can only have all the 'insert' buttons, if I want the youtube button. I don't want to include buttons for tables and flash, but once I include an items setting for the group, I can't have the youtube button.
It is right now adding a totally new toolbar in ckeditor for just one button, what if I want to put it as a last button in 3rd toolbar, or something like that ? I mean how to place the button in specific place on ckeditor ?