function lazyloader_admin_submit in Image Lazyloader 7
Submit handler for the lazyloader settings form.
1 string reference to 'lazyloader_admin_submit'
- lazyloader_admin in ./
lazyloader.admin.inc - Admin Form: UI
File
- ./
lazyloader.admin.inc, line 95 - Lazyloader Admin
Code
function lazyloader_admin_submit($form, &$form_state) {
if ($form_state['values']['op'] == t('Reset')) {
// Reset form values.
$form_state['values']['lazyloader_enable'] = LAZYLOADER_ENABLED;
$form_state['values']['lazyloader_distance'] = LAZYLOADER_DISTANCE;
$form_state['values']['lazyloader_icon'] = LAZYLOADER_ICON;
$form_state['values']['lazyloader_placeholder'] = LAZYLOADER_PLACEHOLDER;
$form_state['values']['lazyloader_paths'] = LAZYLOADER_PATHS;
$form_state['values']['lazyloader_exclude_option'] = LAZYLOADER_EXCLUDE_OPTION;
}
// Rebuild the theme registry if the module was enabled/disabled.
if ($form['lazyloader_enabled']['#default_value'] !== $form_state['values']['lazyloader_enabled']) {
drupal_theme_rebuild();
}
}