WordPress at a glance

show_admin_bar() WP 1.0

Sets the display status of the admin bar.

This can be called immediately upon plugin load. It does not need to be called from a function hooked to the 'init' action.

  • Global. true/false. $show_admin_bar

No Hooks.

Return

Nothing (null).

Usage

show_admin_bar( $show );
$show(true/false) (required)
Whether to allow the admin bar to show.

Code of show_admin_bar: wp-includes/admin-bar.php VER 4.9.8

<?php
function show_admin_bar( $show ) {
	global $show_admin_bar;
	$show_admin_bar = (bool) $show;
}

Related Functions

From tag: toolbar (admin bar)

More from category: Uncategorized

No comments
    Hello, !     Log In . Register