Take the 2-minute tour ×
WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

I know how to disable TinyMCE default buttons with add_filter('tiny_mce_before_init') using theme_advanced_disable parameter, but a button added by a 3rd party plugin seems impossible to hide with tiny_mce_before_init

The available array with add_filter('mce_buttons') returns only the default tinyMCE buttons.

How to disable this tinyMCE button?

share|improve this question

1 Answer 1

up vote 1 down vote accepted

I've found that you can manual set availability button by this attribute theme_advanced_buttons1 (for button in row 1)

Example :

function disable_mce_buttons( $opt ) {
    //set button that will be show in row 1
    $opt['theme_advanced_buttons1'] = 'bold,italic,strikethrough,|,bullist,numlist,blockquote,|,justifyleft,justifycenter,justifyright,|,link,unlink,wp_more,|,spellchecker,wp_fullscreen,wp_adv,separator';
    return $opt;
}

add_filter('tiny_mce_before_init', 'disable_mce_buttons');
share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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