You are here

function ad_text_global_settings_validate in Advertisement 5.2

Same name and namespace in other branches
  1. 5 text/ad_text.module \ad_text_global_settings_validate()
  2. 6.3 text/ad_text.module \ad_text_global_settings_validate()
  3. 6 text/ad_text.module \ad_text_global_settings_validate()
  4. 6.2 text/ad_text.module \ad_text_global_settings_validate()
  5. 7 text/ad_text.module \ad_text_global_settings_validate()

File

text/ad_text.module, line 102
Enhances the ad module to support static text ads.

Code

function ad_text_global_settings_validate($form_id, $form_values) {
  if ((int) $form_values['header_min'] > (int) $form_values['header_max']) {
    form_set_error('header_min', t('The header minimum length can not be greater than the header maximum length.'));
  }
  if ((int) $form_values['body_min'] > (int) $form_values['body_max']) {
    form_set_error('body_min', t('The body minimum length can not be greater than the body maximum length.'));
  }
}