0

Possible Duplicate:
Zend_Validate::is() Static Check, get validation message work around

I need a simple check for right email address. So I use Zend_Validate::is($email, 'EmailAddress'); But it return only "false" for the gmail.com addresses. What is wrong?

Community
  • 1
  • 1
Crusader
  • 1,182
  • 11
  • 22

2 Answers2

0

I think the correct syntax for a validation with Zend is $value = new Zend_Validate_EmailAdress $value->isValid($the variable or string you want to check), that should return true for any email adress.

gerardo flores
  • 402
  • 1
  • 6
  • 28
0

Sorry I mispelled part of the answer, the correct syntax is:

$value = new Zend_Validate_EmailAddress; $value->isValid($the variable or string you want to check);
gerardo flores
  • 402
  • 1
  • 6
  • 28