WP HOOKS
filtrod 3.1.0

show_admin_bar

Args 1Plik wp-includes/admin-bar.phpDokumentacja WP ↗

Opis — z kodu źródłowego

Filters whether to show the admin bar.

Returning false to this hook is the recommended way to hide the admin bar. The user's display preference is used for logged in users.

Parametry

ParametrTypOpis
$show_admin_barboolWhether the admin bar should be shown. Default false.

Wywołanie

Rejestracja callbackaphp
// rejestracja funkcji zwrotnej
add_filter( 'show_admin_bar', 'twoja_funkcja' );

function twoja_funkcja($param_1) {
	// Twój kod
}

Popularne w tej kategorii