filtrod 4.2.0
get_object_terms
Opis — z kodu źródłowego
Filters the terms for a given object or objects.
Parametry
| Parametr | Typ | Opis |
|---|---|---|
$terms | \WP_Term[] | int[] | string[] | string | Array of terms or a count thereof as a numeric string. |
$object_ids | int[] | Array of object IDs for which terms were retrieved. |
$taxonomies | string[] | Array of taxonomy names from which terms were retrieved. |
$args | array | Array of arguments for retrieving terms for the given object(s). See wp_get_object_terms() for details. |
Wywołanie
Rejestracja callbackaphp
// rejestracja funkcji zwrotnej — podaj liczbę argumentów!
add_filter( 'get_object_terms', '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( 'get_object_terms', 'twoja_funkcja', 10, 4 );
function twoja_funkcja($param_1, $param_2, $param_3, $param_4) {
// Twój kod
}Popularne w tej kategorii