You are here

function exif_custom_settings_form_user_submit in EXIF Custom 7

FormAPI submission callback for exif_custom_settings_form_user().

1 string reference to 'exif_custom_settings_form_user_submit'
exif_custom_settings_form_user in ./exif_custom.user.inc
User settings form.

File

./exif_custom.user.inc, line 40
Functionality related to the user settings.

Code

function exif_custom_settings_form_user_submit($form, $form_state) {
  global $user;
  $mid = 0;
  if (isset($form_state['values']['user-default'])) {
    $mid = (int) $form_state['values']['user-default'];
  }
  db_merge('exif_custom_users')
    ->key(array(
    'uid' => $user->uid,
  ))
    ->fields(array(
    'mid' => $mid,
  ))
    ->execute();
}