Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl: the Markov chain saw
 
PerlMonks  

Re: testing for the zero length string (blank value) in cgi fields

by jj808 (Hermit)
on Oct 24, 2001 at 17:52 UTC ( [id://121108]=note: print w/replies, xml ) Need Help??


in reply to testing for the zero length string (blank value) in cgi fields

I think you may have a problem with your quotes. The line
if (param('$neg') eq "") {
will not interpolate the value of $neg, so unless you have a parameter called '$neg' (with the dollar symbol) then this will always evaluate to true, hence trashing the values of your other parameters.

Try it like this instead:

if (param($neg) eq "") {
Cheers,

JJ

Update: Must learn to type as quickly as Masem :-)

Log In?
Username:
Password:

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

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

    No recent polls found