WP HOOKS
filtrod 6.0.0

term_exists_default_query_args

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

Opis — z kodu źródłowego

Filters default query arguments for checking if a term exists.

Parametry

ParametrTypOpis
$defaultsarrayAn array of arguments passed to get_terms().
$termint | stringThe term to check. Accepts term ID, slug, or name.
$taxonomystringThe taxonomy name to use. An empty string indicates the search is against all taxonomies.
$parent_termint | nullID of parent term under which to confine the exists search. Null indicates the search is unconfined.

Wywołanie

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

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

Popularne w tej kategorii