taxonomy_term_confirm_delete_submit

Versions
4.7 – 5
taxonomy_term_confirm_delete_submit($form_id, $form_values)
6 – 7
taxonomy_term_confirm_delete_submit($form, &$form_state)

Submit handler to delete a term after confirmation.

See also

taxonomy_term_confirm_delete()

Code

modules/taxonomy/taxonomy.admin.inc, line 850

<?php
function taxonomy_term_confirm_delete_submit($form, &$form_state) {
  taxonomy_del_term($form_state['values']['tid']);
  taxonomy_check_vocabulary_hierarchy($form['#vocabulary'], $form_state['values']);
  drupal_set_message(t('Deleted term %name.', array('%name' => $form_state['values']['name'])));
  watchdog('taxonomy', 'Deleted term %name.', array('%name' => $form_state['values']['name']), WATCHDOG_NOTICE);
  $form_state['redirect'] = 'admin/content/taxonomy';
  return;
}
?>
Login or register to post comments
 
 

All source code and documentation on this site is released under the terms of the GNU General Public License, version 2 and later. Drupal is a registered trademark of Dries Buytaert.