function email_mail_page_form_validate

cis7 email.module email_mail_page_form_validate($form, &$form_state)
cle7 email.module email_mail_page_form_validate($form, &$form_state)
elmsmedia7 email.module email_mail_page_form_validate($form, &$form_state)
icor7 email.module email_mail_page_form_validate($form, &$form_state)
meedjum_blog7 email.module email_mail_page_form_validate($form, &$form_state)
mooc7 email.module email_mail_page_form_validate($form, &$form_state)

Validate the site-wide contact page form submission.

1 string reference to 'email_mail_page_form_validate'
email_mail_page_form in sites/all/modules/ulmus/email/email.module
Contact form

File

sites/all/modules/ulmus/email/email.module, line 398
Module file for the email module, which creates a email address field.

Code

function email_mail_page_form_validate($form, &$form_state) {
  if (!valid_email_address($form_state['values']['mail'])) {
    form_set_error('mail', t('You must enter a valid e-mail address.'));
  }
  if (preg_match("/\r|\n/", $form_state['values']['subject'])) {
    form_set_error('subject', t('The subject cannot contain linebreaks.'));
    watchdog('mail', 'Email injection exploit attempted in email form subject: ' . check_plain($form_state['values']['subject']), WATCHDOG_NOTICE);
  }
}
Error | ELMSLN API

Error

×

Error message

  • Warning: Cannot modify header information - headers already sent by (output started at /var/www/html/elmsln_community/api.elmsln.org/includes/common.inc:2791) in drupal_send_headers() (line 1499 of /var/www/html/elmsln_community/api.elmsln.org/includes/bootstrap.inc).
  • Error: Call to undefined function apc_delete() in DrupalAPCCache->clear() (line 289 of /var/www/html/elmsln_community/api.elmsln.org/sites/all/modules/apc/drupal_apc_cache.inc).
The website encountered an unexpected error. Please try again later.