You are here

function livechat_admin_license_form_validate in LiveChat 7

Validation callback for license installation form.

File

./livechat.admin.inc, line 229
Administration pages for the LiveChat module.

Code

function livechat_admin_license_form_validate($form, &$form_state) {

  // Validate the license number.
  if ($form_state['values']['op'] === t('Save')) {
    if (!livechat_validate_license($form_state['input']['license_number'])) {
      form_set_error('livechat_license_number', t('LiveChat license number is
        incorrect.'));
    }
  }
}