olaf shiel
asked 5 years ago

There are a lot of private features from my visual editor appearing in the plugin form field. How do I remove these?

Actually, I would like to remove the visual editor all together.

How do I do this?

Thanks

Screenshot

1 Answers
DominicStaff
answered 5 years ago

Hi,
We’ve used the tinyMCE editor of WordPress, if you want to remove several unused icons, you can add the following code to the function.php file:

add_filter("mce_buttons", "tinymce_editor_buttons", 99); //targets the first line
add_filter("mce_buttons_2", "tinymce_editor_buttons_second_row", 99); //targets the second line

function tinymce_editor_buttons($content) {
return array(
    "undo", 
    "redo", 
    "separator",
    "bold", 
    "italic", 
    "underline", 
    "strikethrough", 
    "dwqaCodeEmbed",
    "separator",
    "bullist", 
    "separator",
    //add more here...
    );
}

function tinymce_editor_buttons_second_row($content) {
   //return an empty array to remove this line
    return array();
}

The button control list can be found here: http://www.tinymce.com/wiki.php/TinyMCE3x:Buttons/controls
Hope this helps !

Powered by DW Question & Answer Pro