WP HOOKS
filtrdynamicznyod 2.9.0

edit_user_{$field}

Args 2Plik wp-includes/user.php

Opis — z kodu źródłowego

Filters a user field value in the 'edit' context.

The dynamic portion of the hook name, $field, refers to the prefixed user field being filtered, such as 'user_login', 'user_email', 'first_name', etc.

Parametry

ParametrTypOpis
$valuemixedValue of the prefixed user field.
$user_idintUser ID.

Wywołanie

Rejestracja callbackaphp
// rejestracja funkcji zwrotnej — podaj liczbę argumentów!
add_filter( 'edit_user_{$field}', 'twoja_funkcja', 10, 2 );

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

Popularne w tej kategorii