mce_buttons
This is a WordPress - mce_buttons hook. The plugin just uses it.
Filters the first-row list of TinyMCE buttons (Visual tab).
Usage
add_filter( 'mce_buttons', 'wp_kama_mce_buttons_filter', 10, 2 );
/**
* Function for `mce_buttons` filter-hook.
*
* @param array $mce_buttons First-row list of buttons.
* @param string $editor_id Unique editor identifier, e.g. 'content'. Accepts 'classic-block' when called from block editor's Classic block.
*
* @return array
*/
function wp_kama_mce_buttons_filter( $mce_buttons, $editor_id ){
// filter...
return $mce_buttons;
}
- $mce_buttons(array)
- First-row list of buttons.
- $editor_id(string)
- Unique editor identifier, e.g. 'content'. Accepts 'classic-block' when called from block editor's Classic block.
Where the hook is called
acf/includes/fields/class-acf-field-wysiwyg.php 115
1 => apply_filters( 'mce_buttons', $mce_buttons, $editor_id ),