wpseek.com
WordPress开发者和主题制作者的搜索引擎



show_admin_bar › WordPress Function

Since3.1.0
已弃用n/a
show_admin_bar ( $show )
参数:
  • (bool) $show Whether to allow the admin bar to show.
    Required: Yes
定义在:
文档:

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 {@see 'init'} action.


源码

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