Beefy Boxes and Bandwidth Generously Provided by pair Networks
Your skill will accomplish
what the force of many cannot
 
PerlMonks  

Re: Re: regex to validate e-mail addresses and phone numbers

by seanbo (Chaplain)
on Feb 10, 2004 at 21:21 UTC ( [id://328036]=note: print w/replies, xml ) Need Help??


in reply to Re: regex to validate e-mail addresses and phone numbers
in thread regex to validate e-mail addresses and phone numbers

FWIW, I use: /^\w+\@([\da-zA-Z\-]{1,}\.){1,}[\da-zA-Z-]{2,6}$/ The main idea is that an "_" (underscore) matches on \w, but is not valid as part of a domain name. It is, however, acceptable as part of the username. I use {2,6} since the there are some tld's longer than 4 chars (.museum for example).


perl -e 'print reverse qw/o b n a e s/;'

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://328036]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others wandering the Monastery: (2)
As of 2024-04-25 21:03 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found