Below is a list of some examples of the formats this function will validate.
There are many combinations not shown in these examples, but you should be able to interpolate them.
In addition, it will validate a list of email addresses, separated with commas (see the last example).
It returns a two-dimentional array of the address(es) if the
email address(es) are valid and
false if not.
The array returned is an array of arrays, with each second-level array containing two string values;
these values are
 "The Complete Name Given <email@example.com>" and
Note it does not verify if the email address exists, only if it has a valid format;
using the PHP Class
by Manuel Lemos will verify if it is truly active.
His class only accepts the
firstname.lastname@example.org portion of an email address,
and it is much more limited as to the legal formats it will validate.
We have not played around with the limits of his code, PHP, or our servers
by altering the possible formats his Class will attempt to verify in real time.
Therefore, what our code may validate, his may not; consideration must be taken when applying these together.
- Programmer <email@example.com>
- "Programmer: Website Developer" <firstname.lastname@example.org>
- Programmer <"help: PHP programming"@softmoon-webware.com>
- Programmer in PHP <email@example.com>
- Programmer in PHP <"PHP: programming".firstname.lastname@example.org>
- Even This Works <"strange email: formatting"@"strange domain @ host that *rocks*".com>
- more.strangeness@"strange!".subdomain."hosting @ host that *rocks*".com
- "programming, development"@softmoon-webware.com, "programming, development" <email@example.com>