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.
Se déclenche après la suppression d'un terme de la base de données et le nettoyage du cache. Le crochet {@see 'delete_$taxonomy'} est également disponible pour cibler une taxonomie spécifique.
$term, $tt_id, $taxonomy, $deleted_term, $object_ids
Sortie :
@param int $term Term ID. @param int $tt_id Term taxonomy ID. @param string $taxonomy Taxonomy slug. @param WP_Term $deleted_term Copy of the already-deleted term. @param array $object_ids List of term object IDs.
add_action('delete_term', 'on_term_deleted', 10, 3);
function on_term_deleted($term_id, $tt_id, $taxonomy) {
error_log('Term deleted');
}
Chargement des actualités...