Changeset 17032 for trunk/wp-includes/functions.php
- Timestamp:
- 12/17/2010 09:48:30 PM (15 years ago)
- File:
-
- 1 edited
-
trunk/wp-includes/functions.php (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-includes/functions.php
r17022 r17032 4472 4472 } 4473 4473 4474 /**4475 * Set the display status of the admin bar4476 *4477 * This can be called immediately upon plugin load. It does not need to be called from a function hooked to the init action.4478 *4479 * @since 3.1.04480 *4481 * @param bool $show Whether to allow the admin bar to show.4482 * @return void4483 */4484 function show_admin_bar( $show ) {4485 global $show_admin_bar;4486 $show_admin_bar = (bool) $show;4487 4488 // Remove the object if we are not going to be showing4489 // Otherwise you have to call this function prior to the init hook for it to work!4490 if ( ! $show_admin_bar && isset( $GLOBALS['wp_admin_bar'] ) )4491 $GLOBALS['wp_admin_bar'] = null;4492 }4493 4494 4474 ?>
Note: See TracChangeset
for help on using the changeset viewer.