akcjaod 2.5.0
delete_term
Opis — z kodu źródłowego
Fires after a term is deleted from the database and the cache is cleaned.
The {@see 'delete_$taxonomy'} hook is also available for targeting a specific taxonomy.
Parametry
| Parametr | Typ | Opis |
|---|---|---|
$term | int | Term ID. |
$tt_id | int | Term taxonomy ID. |
$taxonomy | string | Taxonomy slug. |
$deleted_term | \WP_Term | Copy of the already-deleted term. |
$object_ids | array | List of term object IDs. |
Wywołanie
Rejestracja callbackaphp
// rejestracja funkcji zwrotnej — podaj liczbę argumentów!
add_action( 'delete_term', 'twoja_funkcja', 10, 5 );
function twoja_funkcja($param_1, $param_2, $param_3, $param_4, $param_5) {
// Twój kod
}
// rejestracja funkcji zwrotnej — podaj liczbę argumentów!
add_action( 'delete_term', 'twoja_funkcja', 10, 5 );
function twoja_funkcja($param_1, $param_2, $param_3, $param_4, $param_5) {
// Twój kod
}Popularne w tej kategorii