Newbie question - email validation

Discussion in 'Perl Misc' started by newbie@blank.com, Oct 21, 2007.

  1. Guest

    Sorry if this is oft repeated but I cant find anything in faqs

    can someone tell me the simplest (doesnt have to be the cleverest) means
    of validating an email address (not MX lookup just the string itself)

    thanks

    newbie
     
    , Oct 21, 2007
    #1
    1. Advertising

  2. wrote:
    > Sorry if this is oft repeated but I cant find anything in faqs
    >
    > can someone tell me the simplest (doesnt have to be the cleverest)
    > means of validating an email address (not MX lookup just the string
    > itself)


    perldoc -q mail
    "How do I check a valid mail address?"

    jue
     
    Jürgen Exner, Oct 21, 2007
    #2
    1. Advertising

  3. Ron Bergin Guest

    On Oct 21, 9:01 am, wrote:
    > Sorry if this is oft repeated but I cant find anything in faqs
    >
    > can someone tell me the simplest (doesnt have to be the cleverest) means
    > of validating an email address (not MX lookup just the string itself)
    >
    > thanks
    >
    > newbie


    use Email::Valid;

    my $validate = Email::Valid->new;
    my $address = '';

    print $validate->address($address) ? 'yes' : 'no';
     
    Ron Bergin, Oct 21, 2007
    #3
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Peter
    Replies:
    0
    Views:
    3,428
    Peter
    Jul 1, 2003
  2. John Silver
    Replies:
    0
    Views:
    634
    John Silver
    Feb 4, 2005
  3. Tee

    Email ErrorPage to email

    Tee, Jun 23, 2004, in forum: ASP .Net
    Replies:
    0
    Views:
    397
  4. bateman5
    Replies:
    10
    Views:
    341
    Brian Genisio
    Feb 17, 2004
  5. Jerry C.
    Replies:
    8
    Views:
    278
    Uri Guttman
    Nov 23, 2003
Loading...

Share This Page