WP HOOKS
filtrod 2.7.0

get_usernumposts

Args 4Plik wp-includes/user.phpDokumentacja WP ↗

Opis — z kodu źródłowego

Filters the number of posts a user has written.

Parametry

ParametrTypOpis
$countstringThe user's post count as a numeric string.
$useridintUser ID.
$post_typestring | arraySingle post type or array of post types to count the number of posts for.
$public_onlyboolWhether to limit counted posts to public posts.

Wywołanie

Rejestracja callbackaphp
// rejestracja funkcji zwrotnej — podaj liczbę argumentów!
add_filter( 'get_usernumposts', 'twoja_funkcja', 10, 4 );

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

Popularne w tej kategorii