mce_buttons_2 WordPress Filter Hook

The mce_buttons_2 hook is used to add new buttons to the second row of the WordPress visual editor. This hook is called by the WordPress core function `mce_buttons()`.

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

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


Parameters

$mce_buttons_2

(array)Second-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 ↑

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.