mce_buttons WordPress Filter Hook

The mce_buttons hook is used to add custom buttons to the WordPress TinyMCE editor. This hook can be used to add new buttons or remove existing buttons from the editor.

apply_filters( 'mce_buttons', array $mce_buttons, string $editor_id ) #

Filters the first-row list of TinyMCE buttons (Visual tab).


Parameters

$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.


Top ↑

More Information

See other relevant mce_buttons hooks:


Top ↑

Source

File: wp-includes/class-wp-editor.php

View on Trac



Top ↑

Changelog

Changelog
VersionDescription
3.3.0The $editor_id parameter was added.
2.0.0Introduced.

The content displayed on this page has been created in part by processing WordPress source code files which are made available under the GPLv2 (or a later version) license by theĀ Free Software Foundation. In addition to this, the content includes user-written examples and information. All material is subject to review and curation by the WPPaste.com community.