in reply to CGI + regex help

Two things. First off, why aren't you using Email::Valid

Secondly, I just searched CGI's documentation, but I don't think you can retrieve a parameter using $q->param(-name => 'next_email');. I think that syntax is only for setting a parameter's value. I could be wrong, but over 100 mentions of param() in the perldoc and not one example or mention of retrieval using the named syntax. I would try using the direct syntax, instead.

Also, You're mentioning having issues with the CGI as object. Make sure that you're not mixing procedural and OO interfaces. That's a really easy way to move to a rubber room.

------
We are the carpenters and bricklayers of the Information Age.

The idea is a little like C++ templates, except not quite so brain-meltingly complicated. -- TheDamian, Exegesis 6

Please remember that I'm crufty and crochety. All opinions are purely mine and all code is untested, unless otherwise specified.

Replies are listed 'Best First'.
Re: Re: CGI + regex help
by antirice (Priest) on Oct 09, 2003 at 22:39 UTC

    It works:

    # perl -MCGI -le'print "works" if CGI->new()->param(-name=>"a")' a=1 works #

    Also, good point about Email::Valid.

    antirice    
    The first rule of Perl club is - use Perl
    The
    ith rule of Perl club is - follow rule i - 1 for i > 1