function avatar_selection_config_form_submit in Avatar Selection 5.2
Same name and namespace in other branches
- 5 avatar_selection.module \avatar_selection_config_form_submit()
- 6 avatar_selection.admin.inc \avatar_selection_config_form_submit()
- 7 avatar_selection.admin.inc \avatar_selection_config_form_submit()
Submit the settings form in the Avatar Selection administration page.
Parameters
$form_id: The form id.
$form_values: Array containing the form values submitted.
File
- ./
avatar_selection.module, line 987 - The Avatar Selection module allows the user to pick an avatar image from a list already loaded by an administrative user, and to the administrator to disable uploading other avatar files by the user.
Code
function avatar_selection_config_form_submit($form_id, $form_values) {
$op = $form_values['op'];
if ($op == t('Update')) {
// Save system variables.
variable_set('avatar_selection_disable_user_upload', $form_values['disable_user_upload']);
variable_set('avatar_selection_force_user_avatar_reg', $form_values['force_set_image_reg']);
variable_set('avatar_selection_force_user_avatar', $form_values['force_set_image']);
variable_set('avatar_selection_avatar_per_page', $form_values['avatar_per_page']);
variable_set('avatar_selection_set_random_default', $form_values['set_random_default']);
variable_set('avatar_selection_distinctive_avatars', $form_values['distinctive_avatars']);
drupal_set_message(t('Configuration has been updated.'));
}
}