in reply to Re: Re: error management...
in thread Newbie error management question
To avoid "use of unintialized value" errors, I had to add some lines to check for NULL occurances of the form variables (and $TRACKER - which gave a NULL value from the command line{???}):
$TRACKER = $ENV{'HTTP_REFERER'}; if (!($TRACKER)) { $TRACKER = $ENV{'REMOTE_ADDR'};} #added if (!($TRACKER)) { $TRACKER = ""; } # why would these ENV variables BOTH be blank ??? $client_email = $query->param('email'); #added if (!($client_email)) { $client_email=""; } chomp($client_email); #added to other query vars...
This seems somewhat redundant, BUT... those first few variables were happening BEFORE I sent the headers.
is there a better way to assure that the form values that are needed are not NULL before proceeding?
|
|---|