Beefy Boxes and Bandwidth Generously Provided by pair Networks
Problems? Is your data what you think it is?
 
PerlMonks  

Re: Validating the contents of scalars using an array based list

by JPaul (Hermit)
on Apr 04, 2003 at 15:53 UTC ( [id://248106]=note: print w/replies, xml ) Need Help??


in reply to Validating the contents of scalars using an array based list

Thanks all, many great ideas which I've percolated into my final solution.
If you see any problems, please drop a post :)
I chose to instead of checking the perl variables, check the CGI parameters - which made much more sense, thanks for the ideas Monks;
my @varlist = qw(var1 var2 var3); foreach (@varlist) { if (!defined $cgi->param($_) || $cgi->param($_) eq "") { &complain($_); } }
Where &complain() can translate var# into the HTML side field name (ie. "Phone number", instead of 'phone').

Cheers all;
JP,
-- Alexander Widdlemouse undid his bellybutton and his bum dropped off --

Log In?
Username:
Password:

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

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

    No recent polls found