system_modules_uninstall_validate

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

Validates the submitted uninstall form.

Parameters

$form_id The form ID.

$form_values Submitted form values.

Code

modules/system/system.module, line 1731

<?php
function system_modules_uninstall_validate($form_id, $form_values) {
  // Form submitted, but no modules selected.
  if (!count(array_filter($form_values['uninstall']))) {
    drupal_set_message(t('No modules selected.'), 'error');
    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.