wpseek.com
Uma área de pesquisa sobre o WordPress para devs e autores do tema



wp_enqueue_admin_bar_header_styles › WordPress Function

Desde6.4.0
Obsoleton/a
wp_enqueue_admin_bar_header_styles ( Sem parâmetros )
Definido em:
Codex:

Enqueues inline style to hide the admin bar when printing.



Fonte

function wp_enqueue_admin_bar_header_styles() {
	// Back-compat for plugins that disable functionality by unhooking this action.
	$action = is_admin() ? 'admin_head' : 'wp_head';
	if ( ! has_action( $action, 'wp_admin_bar_header' ) ) {
		return;
	}
	remove_action( $action, 'wp_admin_bar_header' );

	wp_add_inline_style( 'admin-bar', '@media print { #wpadminbar { display:none; } }' );
}