Action
rpress_settings_tab_top
On this page
Fires at the top of a settings tab, before its fields, for the main section.
Runs inside the settings form before the sections are printed, only when the current section is main. The active tab ID is passed, so a callback should compare it to target one tab. Echo markup directly.
Parameters#
| Parameter | Type | Description |
|---|---|---|
$active_tab | string | The ID of the active settings tab. |
Example#
function my_settings_tab_top( $active_tab ) {
if ( 'gateways' !== $active_tab ) {
return;
}
echo '<p class="description">' . esc_html__( 'Test mode charges no cards.', 'my-plugin' ) . '</p>';
}
add_action( 'rpress_settings_tab_top', 'my_settings_tab_top', 10, 1 );
Source#
Fired from:
includes/admin/settings/display-settings.php(line 124), inrpress_options_page()
See also#
rpress_settings_tab_top_%7B%24active_tab%7D_%7B%24section%7Drpress_settings_tab_bottom
Was this page helpful?
