Skip navigation
Help

hook_taxonomy_vocabulary_delete

7 taxonomy.api.php hook_taxonomy_vocabulary_delete($vocabulary)

Respond to the deletion of taxonomy vocabularies.

Modules implementing this hook can respond to the deletion of taxonomy vocabularies from the database.

Parameters

$vocabulary: A taxonomy vocabulary object.

Related topics

2 functions implement hook_taxonomy_vocabulary_delete()

1 invocation of hook_taxonomy_vocabulary_delete()

File

drupal/modules/taxonomy/taxonomy.api.php, line 81
Hooks provided by the Taxonomy module.

Code

function hook_taxonomy_vocabulary_delete($vocabulary) {
  if (variable_get('taxonomy_' . $vocabulary->vid . '_synonyms', FALSE)) {
    variable_del('taxonomy_' . $vocabulary->vid . '_synonyms');
  }
}