wp_admin_bar_sidebar_toggle

Advertisement

Summery Summery

Add the sidebar toggle button.

Syntax Syntax

wp_admin_bar_sidebar_toggle( WP_Admin_Bar $wp_admin_bar )

Parameters Parameters

$wp_admin_bar

(Required)

Source Source

File: wp-includes/admin-bar.php

function wp_admin_bar_sidebar_toggle( $wp_admin_bar ) {
	if ( is_admin() ) {
		$wp_admin_bar->add_node(
			array(
				'id'    => 'menu-toggle',
				'title' => '<span class="ab-icon"></span><span class="screen-reader-text">' . __( 'Menu' ) . '</span>',
				'href'  => '#',
			)
		);
	}
}

Advertisement

Changelog Changelog

Changelog
Version Description
3.8.0 Introduced.

Advertisement

Leave a Reply