3

Is there a way to add the align buttons to the toolbar without downloading the full version of ckeditor?

Thanxx

Nomz
  • 151
  • 1
  • 2
  • 13

3 Answers3

4

You need the justify plugin. Also see official docs.

oleq
  • 15,697
  • 1
  • 38
  • 65
  • I also added the Bidi plugin, but when adding the buttons to the toolbar they are disabled. Do you know why? – Nomz Aug 19 '13 at 07:18
2

Just add justify plugin.

config.extraPlugins = "justify";
Sagar
  • 4,473
  • 3
  • 32
  • 37
0

The best solution, I found for my ckeditor 4 version:

https://dev.ckeditor.com/ticket/10320

var editor = CKEDITOR.replace( 'editor1', {
                //allowedContent : true
                enterMode : CKEDITOR.ENTER_BR,
                toolbar : [
                ['Font', 'FontSize'], ['TextColor', 'BGColor'], ['Bold', 'Italic', 'Underline', 'Strike'], ['Subscript', 'Superscript'],
                ['JustifyLeft', 'JustifyRight', 'JustifyCenter', 'JustifyBlock'], ['NumberedList', 'BulletedList'], ['Outdent', 'Indent', 'Blockquote'], ['Table', 'HorizontalRule', 'SpecialChar'], ['Link', 'Unlink', 'Image'],
                ['Cut', 'Copy', 'Paste', 'PasteText', 'PasteFromWord'], ['Undo', 'Redo', '-', 'Find', 'Replace', '-', 'SelectAll', 'RemoveFormat'], ['Source']
                ]
            } );

Just added ['JustifyLeft', 'JustifyRight', 'JustifyCenter', 'JustifyBlock'] in ckeditor's toolbar and It worked for me like charm. Thanks for asking this question.

Kamlesh
  • 5,233
  • 39
  • 50