You are here

function trumba_admin_settings_form_validate in Trumba 7

Validates the values that have been set using the settings form.

File

./trumba.admin.inc, line 29
Administrative form for Trumba module.

Code

function trumba_admin_settings_form_validate($form, &$form_state) {

  // Make sure this not an attack.
  $form['trumba_webname']['#value'] = check_plain($form['trumba_webname']['#value']);

  // If it is, complain.
  if (empty($form['trumba_webname']['#value'])) {
    form_set_error('trumba_webname', 'Please enter a valid Trumba webname');
  }
}