Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

TinyMCE not giving me bullist or numlist icons in menu

Tags:

tinymce

I have a page with multiple textarea's that I am converting to tinymce fields.

<script src='//cdn.tinymce.com/4/tinymce.min.js'></script>
<script>
    tinymce.init({
        selector: '.input-textarea',
        toolbar: 'bold italic | bullist numlist indent outdent',
        statusbar: false,
        menubar: false,
        browser_spellcheck: true,
        contextmenu: false
    });
</script>

The textareas are all class input-textarea, and the tinymce editor is loading jsut fine. Except, for some reason all the menu buttons are showing except the bullist and the numlist. Am I missing something?

like image 954
Tyson of the Northwest Avatar asked Dec 06 '16 00:12

Tyson of the Northwest


1 Answers

You need to load the lists plugin to use those toolbar buttons:

tinymce.init({
  selector: "textarea",
  plugins: [
    "advlist autolink lists link image charmap print preview anchor",
    "searchreplace visualblocks code fullscreen",
    "insertdatetime media table contextmenu paste"
  ],
  toolbar: "bullist numlist"
});

There is also an advlist plugin with additional features that you may be interested in using:

https://www.tinymce.com/docs/plugins/advlist/

like image 146
Michael Fromin Avatar answered Nov 08 '22 00:11

Michael Fromin