function taxonomy_vocabulary_confirm_reset_alphabetical_submit

Same name and namespace in other branches
  1. 7.x drupal-7.x/modules/taxonomy/taxonomy.admin.inc \taxonomy_vocabulary_confirm_reset_alphabetical_submit()

Submit handler to reset a vocabulary to alphabetical order after confirmation.

See also

taxonomy_vocabulary_confirm_reset_alphabetical()

1 call to taxonomy_vocabulary_confirm_reset_alphabetical_submit()
taxonomy_overview_terms_submit in drupal-6.x/modules/taxonomy/taxonomy.admin.inc
Submit handler for terms overview form.

Archivo

drupal-6.x/modules/taxonomy/taxonomy.admin.inc, line 920
Administrative page callbacks for the taxonomy module.

Código

function taxonomy_vocabulary_confirm_reset_alphabetical_submit($form, &$form_state) {
  db_query('UPDATE {term_data} SET weight = 0 WHERE vid = %d', $form_state['values']['vid']);
  drupal_set_message(t('Reset vocabulary %name to alphabetical order.', array('%name' => $form_state['values']['name'])));
  watchdog('taxonomy', 'Reset vocabulary %name to alphabetical order.', array('%name' => $form_state['values']['name']), WATCHDOG_NOTICE);
  $form_state['redirect'] = 'admin/content/taxonomy/' . $form_state['values']['vid'];
}