powerhouse has asked for the wisdom of the Perl Monks concerning the following question:
So my question is do you know of a better more efficient way to validate an email address?if ($f->{name} eq "email" && ($value =~ /(@.*@)|(\.\.)|(@\.)|(\.@)|(^\ +.) / || $value !~ /^.+\@(\[?)[a-zA-Z0-9\-\.]+\.([a-zA-Z]{2,3}|[0-9]{1 +,3})(\]?)$/)) { $f->{errors} = "Invalid Email Address!"; $errors++; }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: checking email syntax
by kyle (Abbot) on Feb 05, 2008 at 17:20 UTC | |
|
Re: checking email syntax
by mr_mischief (Monsignor) on Feb 05, 2008 at 18:05 UTC | |
|
Re: checking email syntax
by toolic (Bishop) on Feb 05, 2008 at 17:23 UTC | |
|
Re: checking email syntax
by dsheroh (Monsignor) on Feb 05, 2008 at 18:16 UTC | |
|
Re: checking email syntax
by bradcathey (Prior) on Feb 05, 2008 at 19:11 UTC | |
|
Re: checking email syntax
by superfrink (Curate) on Feb 06, 2008 at 04:38 UTC |