You are here

function tokenauth_admin_settings_validate in Token authentication 7

Same name and namespace in other branches
  1. 5 tokenauth.module \tokenauth_admin_settings_validate()
  2. 6.2 tokenauth.pages.inc \tokenauth_admin_settings_validate()
  3. 6 tokenauth.pages.inc \tokenauth_admin_settings_validate()

Validate callback.

File

./tokenauth.pages.inc, line 77
Provides administrative user interface for Tokenauth module.

Code

function tokenauth_admin_settings_validate($form, &$form_state) {
  if ($form_state['values']['op'] == t('Reset tokens')) {
    drupal_goto('admin/settings/tokenauth/reset');
  }
  if ($form_state['values']['tokenauth_length'] > 33) {
    form_set_error('tokenauth_length', t('The maximum token length is 32.'));
  }
}