You are here

function user_badges_settings_form in User Badges 5

Same name and namespace in other branches
  1. 6.2 user_badges.admin.inc \user_badges_settings_form()
  2. 6 user_badges.admin.inc \user_badges_settings_form()
  3. 7.4 includes/user_badges.admin.inc \user_badges_settings_form()
  4. 7 user_badges.admin.inc \user_badges_settings_form()
  5. 7.2 user_badges.admin.inc \user_badges_settings_form()
  6. 7.3 user_badges.admin.inc \user_badges_settings_form()
1 string reference to 'user_badges_settings_form'
user_badges_menu in ./user_badges.module
Implementation of hook_menu().

File

./user_badges.module, line 953
@brief User Badges module file

Code

function user_badges_settings_form() {
  $form['showone'] = array(
    '#type' => 'checkbox',
    '#title' => t('Only show the most highest-level badge'),
    '#default_value' => variable_get('user_badges_showone', 0),
    '#description' => t('If checked, only the badge with the lightest weight will be shown.') . '<br/>' . t('Note that if multiple badges have the same lightest weight, only one of them will appear
      (first by alphabetical order).'),
  );
  $form['showblocked'] = array(
    '#type' => 'checkbox',
    '#title' => t('Only show blocked user badge'),
    '#default_value' => variable_get('user_badges_showblocked', 0),
    '#description' => t('If checked, only the badge associated to blocked users will be shown, overriding other badges
      the user eventually has as well as the preciding options.') . '<br/>' . t('Note that if there is no badge associated to blocked users, no badges will appear.') . '</br>' . t('This option only acts on blocked users and has no repercussions on active user badges.'),
  );
  $form[] = array(
    '#type' => 'submit',
    '#value' => t('Save Settings'),
  );
  return $form;
}