filtrod 6.0.0
term_exists_default_query_args
Opis — z kodu źródłowego
Filters default query arguments for checking if a term exists.
Parametry
| Parametr | Typ | Opis |
|---|---|---|
$defaults | array | An array of arguments passed to get_terms(). |
$term | int | string | The term to check. Accepts term ID, slug, or name. |
$taxonomy | string | The taxonomy name to use. An empty string indicates the search is against all taxonomies. |
$parent_term | int | null | ID 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
}
// 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