to CKEditor 4.
WePAGE method
1.config.js method
// both are array types config.toolbar = [ ['Source', '-', 'Bold', 'Italic'], ['Cut', 'Copy', 'Paste', 'PasteText', 'PasteFromWord'], '/', ['Checkbox', 'Radio', 'TextField', 'Textarea', 'Select','Button'] ]; config.toolbar = 'Basic'; config.toolbar_Basic =[ ['Bold', 'Italic', '-', 'NumberedList', 'BulletedList', '-', 'Link', 'Unlink', '-', 'About'] ]; config.toolbarGroups = [ { name: 'document', groups: [ 'mode', 'document', 'doctools' ] }, { name: 'clipboard', groups: [ 'clipboard', 'undo' ] }, { name: 'editing', groups: [ 'find', 'selection', 'spellchecker' ] }, { name: 'forms' }, '/', { name: 'basicstyles', groups: [ 'basicstyles', 'cleanup' ] }, { name: 'paragraph', groups: [ 'list', 'indent', 'blocks', 'align', 'bidi' ] }, { name: 'links' }, { name: 'insert' }, '/', { name: 'styles' }, { name: 'colors' }, { name: 'tools' }, { name: 'others' }, { name: 'about' } ];
Note: "/" means the toolbar wraps, "-" means the separation line between the tool icons "|"
2.IN-PAGE mode
CKEDITOR.replace( 'editor1', { toolbar : [ ['Styles', 'Format'], ['Bold', 'Italic', '-', 'NumberedList', 'BulletedList', '-', 'Link', '-', 'About'] ] });
The definition of the toolbar is explained in English and Chinese:
Source = source mode - Save = save (submit form) NewPage = New Preview = preview - = dividing line Templates = Templates Cut = cut Copy = copy Paste = paste PasteText = Paste as plain text PasteFromWord = Paste from MS WORD - Print = print SpellChecker = Spell Checker Scayt = Instant Spell Check Undo = undo Redo = redo - Find = find Replace = replace - SelectAll = select all RemoveFormat = remove format Form = form Checkbox = Checkbox Radio = radio button TextField = single line of text Textarea = multi-line text Select = list/menu Button = button ImageButton = Image button HiddenField = Hidden Field / Bold = bold Italic = inclined Underline = underline Strike = strikethrough - Subscript = subscript Superscript = superscript NumberedList = Numbered List BulletedList = list of items - Outdent = reduce indent Indent = increase indent Blockquote = block quote CreateDiv = Create DIV container JustifyLeft = justify left JustifyCenter = Center JustifyRight = justify right JustifyBlock = Justify Block BidiLtr = text direction left to right BidiRtl = text direction right to left Link = insert/edit hyperlink (upload file) Unlink = unlink hyperlink Anchor = insert/edit anchor link Image = image(upload) Flash = animation (upload) Table = table HorizontalRule = Insert horizontal line Smiley = insert emoji SpecialChar = insert special character PageBreak = Insert page break / Styles = style shortcuts Format = text format Font = font FontSize = text size TextColor = text color BGColor = background color Maximize = full screen edit mode ShowBlocks = show blocks - About = show about
Transfer: http://www.cnblogs.com/answercard/p/3709463.html