function themekey_ui_settings_form_submit in ThemeKey 7.2
Same name and namespace in other branches
- 6.4 themekey_ui_admin.inc \themekey_ui_settings_form_submit()
- 6.2 themekey_ui_admin.inc \themekey_ui_settings_form_submit()
- 6.3 themekey_ui_admin.inc \themekey_ui_settings_form_submit()
- 7.3 themekey_ui_admin.inc \themekey_ui_settings_form_submit()
- 7 themekey_ui_admin.inc \themekey_ui_settings_form_submit()
Form submission handler for themekey_ui_settings_form().
See also
File
- ./
themekey_ui_admin.inc, line 146
Code
function themekey_ui_settings_form_submit($form, &$form_state) {
//
foreach ($form_state['values'] as $key => $value) {
if (0 === strpos($key, 'themekey_ui_')) {
variable_set($key, $value);
}
}
themekey_update_static_rule('themekey_ui:node_triggers_theme', $form_state['values']['themekey_ui_nodeform']);
themekey_update_static_rule('themekey_ui:node_author_triggers_theme', $form_state['values']['themekey_ui_author']);
themekey_update_static_rule('themekey_ui:blog_author_triggers_theme', array_key_exists('themekey_ui_blog_author', $form_state['values']) ? $form_state['values']['themekey_ui_blog_author'] : FALSE);
drupal_set_message(t('The configuration options have been saved.'));
}