You are here

function user_badges_settings_form_validate in User Badges 6.2

Same name and namespace in other branches
  1. 6 user_badges.admin.inc \user_badges_settings_form_validate()
  2. 7.4 includes/user_badges.admin.inc \user_badges_settings_form_validate()
  3. 7 user_badges.admin.inc \user_badges_settings_form_validate()
  4. 7.2 user_badges.admin.inc \user_badges_settings_form_validate()
  5. 7.3 user_badges.admin.inc \user_badges_settings_form_validate()

validate user_badges_settings_form input

File

./user_badges.admin.inc, line 682
@brief User Badges admin functions

Code

function user_badges_settings_form_validate($form, $form_state) {

  // 'showone' must be numeric.
  if (!is_numeric($form_state['values']['showone']) || $form_state['values']['showone'] < 0) {
    form_set_error('showone', t('Must be a positive number.'));
  }
}