Re: [PHP] More Email ereg Validation

2001-04-05 Thread Dan Wilson
: > : Here's a quick patch.. =3D) : > : ([a-z0-9_\.\-]+)@([a-z0-9\.-]+).([a-z]{2}[a-z]?) : > Does anyone else (a regex guru) have any other suggestions? : I'm by no means an reg-exp-expert (hate these things) : /[a-z0-9_.-]+@+[a-z0-9._-]+\.[a-z]{2,4}/i : should do. : -fkr And the winner is

RE: [PHP] More Email ereg Validation

2001-04-05 Thread stout
Or ([a-zA-Z0-9_\.\-]+)@([a-zA-Z0-9-]+).([a-zA-Z\.]+.?[a-zA-Z]) >> Sorry, but that doesn't work. I thought it would, but it only does two >> characters on the top level domain again. Tested at >> http://www.php.comzept.de/rexpr (thanks Jörg!) >> >> Does anyone else (a regex guru) have a

Re: [PHP] More Email ereg Validation

2001-04-05 Thread Felix Kronlage
On Thu, Apr 05, 2001 at 10:08:13AM -0600, Dan Wilson wrote: > : Here's a quick patch.. =) > : ([a-z0-9_\.\-]+)@([a-z0-9\.-]+).([a-z]{2}[a-z]?) > Does anyone else (a regex guru) have any other suggestions? I'm by no means an reg-exp-expert (hate these things) /[a-z0-9_.-]+@+[a-z0-9._-]+\.[a-z]{2

RE: [PHP] More Email ereg Validation

2001-04-05 Thread Jaime Bozza
> Sorry, but that doesn't work. I thought it would, but it only does two > characters on the top level domain again. Tested at > http://www.php.comzept.de/rexpr (thanks Jörg!) > > Does anyone else (a regex guru) have any other suggestions? The most recent regex you had: ([a-z0-9_\.\-]+)@

Re: [PHP] More Email ereg Validation

2001-04-05 Thread Dan Wilson
: [EMAIL PROTECTED] says... : }I'm trying to parse the different "parts" of an email address both for : }validation and munging. : } : }I have the following regex: : }([a-z0-9_\.\-]+)@([a-z0-9\.-]+).([a-z]{3}) : } : }This works great, except it doesn't accept the country code domains (.au, : }etc)

Re: [PHP] More Email ereg Validation

2001-04-05 Thread Renze Munnik
Jason Murray wrote: > >Function validEmail($emailaddress) >{ > // Decides if the email address is valid. Checks syntax and DNS > // records, for total smartass value. Returns "valid", "invalid-mx" > // or "invalid-form". > > if > (eregi("^[0-9a-z]([-_.]?[0-9a-z])*@[0-

Re: [PHP] More Email ereg Validation

2001-04-04 Thread Jeff Carnahan
In article <000501c0bd59$b637e7b0$[EMAIL PROTECTED]>, [EMAIL PROTECTED] says... }I'm trying to parse the different "parts" of an email address both for }validation and munging. } }I have the following regex: }([a-z0-9_\.\-]+)@([a-z0-9\.-]+).([a-z]{3}) } }This works great, except it doesn't accept

RE: [PHP] More Email ereg Validation

2001-04-04 Thread Jason Murray
> This works great, except it doesn't accept the country code > domains (.au, etc). So I changed the number of characters to {2,3} at the > end of the regex: > ([a-z0-9_\.\-]+)@([a-z0-9\.-]+).([a-z]{2,3}) > > But then this works for the country code domains, but cuts > off a character of the

[PHP] More Email ereg Validation

2001-04-04 Thread Dan Wilson
I'm trying to parse the different "parts" of an email address both for validation and munging. I have the following regex: ([a-z0-9_\.\-]+)@([a-z0-9\.-]+).([a-z]{3}) This works great, except it doesn't accept the country code domains (.au, etc). So I changed the number of characters to {2,3} at