system_modules_uninstall_submit

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

Processes the submitted uninstall form.

Parameters

$form_id The form ID.

$form_values Submitted form values.

Code

modules/system/system.module, line 1747

<?php
function system_modules_uninstall_submit($form_id, $form_values) {
  // Make sure the install API is available.
  include_once './includes/install.inc';

  // Call the uninstall routine for each selected module.
  foreach (array_filter($form_values['uninstall']) as $module => $value) {
    drupal_uninstall_module($module);
  }
  drupal_set_message(t('The selected modules have been uninstalled.'));
  drupal_goto('admin/build/modules/uninstall');
}
?>
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.