function prod_check_prod_mode_form_submit in Production check & Production monitor 7
Same name and namespace in other branches
- 6 includes/prod_check.admin.inc \prod_check_prod_mode_form_submit()
Setup site for production mode: submit.
File
- includes/
prod_check.admin.inc, line 618
Code
function prod_check_prod_mode_form_submit($form, &$form_state) {
// Adjust settings.
$variables = prod_check_prod_mode_settings($form_state['values']);
drupal_set_message(t('The following settings have been changed: %variables.', array(
'%variables' => implode(', ', array_keys($variables)),
)));
// Enable / disable modules.
$modules = prod_check_prod_mode_modules($form_state['values']);
if (!empty($modules['disable'])) {
drupal_set_message(t('The following modules have been <strong>disabled</strong>: %modules.', array(
'%modules' => implode(', ', $modules['disable']),
)));
}
if (!empty($modules['enable'])) {
drupal_set_message(t('The following modules have been <strong>enabled</strong>: %modules.', array(
'%modules' => implode(', ', $modules['enable']),
)));
}
$form_state['redirect'] = 'admin/reports/prod-check';
}