Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

tinymce: default toolbar specification

Tags:

tinymce

I am using tinymce editor. I am using default toolbars. I mean I am not specifying any additional toolbars:

<script type="text/javascript">
    tinymce.init({
        selector: "textarea",
        height: 400,
        statusbar: false,
        menubar:false
     });
  </script>

However, now I want to add "font-size" and "table" toolbars to the default. Can I find somewhere specification of default toolbars?

Here is how default editor looks like: enter image description here

I was trying to create toolbar option bymyself but I never get the same as in default. So I would like to find default tinymce toolbar specification and add there "table" and "fontsize" options.

like image 951
renathy Avatar asked Sep 16 '13 07:09

renathy


People also ask

How do I disable TinyMCE editor toolbar?

To disable the toolbar, the toolbar option should be provided a boolean value of false .

Is TinyMCE free for commercial use?

Is TinyMCE free? Yes. The TinyMCE core editor is free to use for commercial and noncommercial purposes.

What is TinyMCE selector?

Selector engine, enables you to select controls by using CSS like expressions. We currently only support basic CSS expressions to reduce the size of the core and the ones we support should be enough for most cases.


2 Answers

You should have figured it out by now but for the next one finding this, this should do the trick:

<script type="text/javascript">
    tinymce.init({
         selector: "textarea",
         height: 400,
         statusbar: false,
         menubar:false,
         toolbar: "undo redo | styleselect | bold italic | alignleft aligncenter alignright alignjustify | bullist numlist outdent indent | table | fontsizeselect"
      });
</script>

So default one is:

         toolbar: "undo redo | styleselect | bold italic | alignleft aligncenter alignright alignjustify | bullist numlist outdent indent"
like image 83
Axi Avatar answered Sep 28 '22 10:09

Axi


For TinyMCE 5, the default toolbar configuration is:

toolbar: 'undo redo | styleselect | bold italic | alignleft aligncenter alignright alignjustify | outdent indent'

More about TinyMCE toolbar configuration here: https://www.tiny.cloud/blog/tinymce-toolbar

like image 30
Ben Long Avatar answered Sep 28 '22 09:09

Ben Long