I want to unregister a custom tinymce plugin in one of my child themes. The custom tinymce plugin uses basically:



add_filter( "mce_external_plugins", "foo_add_buttons" );
add_filter( 'mce_buttons', 'foo_register_buttons' );

What is the best way to remove this such that performance is the best? The two options I came up with are:

  1. remove_filter("mce_external_plugins"); & remove_filter( 'mce_buttons', 'foo_register_buttons' );?
  2. add_filter('tiny_mce_before_init', 'disable_mce_buttons'); and simply remove the buttons that the parent theme adds?

2 Answers 2


Option 2 was the only one that worked correctly.

function disable_mce_buttons($settings){

    $settings['external_plugins'] = '';
    $settings['toolbar3'] = '';
    return $settings;
add_filter('tiny_mce_before_init', 'disable_mce_buttons');

Option 1 should work if you run the remove_filter on a hook.

function wpa_145664(){
  remove_filter( 'mce_buttons', 'foo_register_buttons' );
add_action('admin_init', 'wpa_145664');

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.