Re: ereg matching email address
| From: | Lars Torben Wilson | Date: | Tue, 05 Sep 2000 18:29:36 +0000 |
| Subject: | Re: ereg matching email address | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-15349@lists.php.net to get a copy of this message | ||
kris@grinz.com writes:
> Hi,
>
> I am having trouble with ereg matching an email address. I am
> unable to find any examples of this explicitly. Can someone send
> me the ereg pattern for checking whether an email address is valid
> or not? I have tried a few ereg patterns with no success.
>
> Kris
Look in the mailing list archives, there are a zillion. Read RFC 822
carefully and pick the one which works best for you. However, you
should be aware that a fully RFC 822-compliant matching regex fills
something like an entire page in a book on the topic. :) It's
definitely non-trivial.
--
+----------------------------------------------------------------+
|Torben Wilson <torben@php.net> Netmill iTech|
|http://www.coastnet.com/~torben http://www.netmill.fi|
|Ph: 1 250 383-9735 torben@netmill.fi|
+----------------------------------------------------------------+