function hansel_ui_switch_configure_form_submit in Hansel breadcrumbs 7
Same name and namespace in other branches
- 8 hansel_ui/hansel_ui.module \hansel_ui_switch_configure_form_submit()
Form submit handler for switch configuration forms.
Saves the switch configuration to the database.
1 string reference to 'hansel_ui_switch_configure_form_submit'
- hansel_ui_switch_configure_form in hansel_ui/
hansel_ui.module - Alter a switch configuration form before passing it to the rendering engine.
File
- hansel_ui/
hansel_ui.module, line 586 - Hansel UI module
Code
function hansel_ui_switch_configure_form_submit($form, &$form_state) {
$arguments = $form_state['values'];
unset($arguments['op']);
unset($arguments['save']);
unset($arguments['form_build_id']);
unset($arguments['form_token']);
unset($arguments['form_id']);
db_query("UPDATE {hansel_rule_action_switch} SET arguments = :args WHERE rid = :rid", array(
':args' => serialize($arguments),
':rid' => $form['#rid'],
));
cache_clear_all('hansel_config', 'cache');
$form_state['redirect'] = 'admin/config/search/hansel';
}