S_Shrum has asked for the wisdom of the Perl Monks concerning the following question:
My script allows for a &page= parameter. I am trying to set the script up to deal with the case of the call omitting this param and setting it to the &defaultpage parameter.
Note: using CGI.pm to handle parsing
What I'm tring to do: if ( $input->param('page') == "" && $input->param('defaultpage') != "" ) {
...but this line never works. Am I testing for the right thing? I tried: if ( $input->param('page') == null && $input->param('defaultpage') != "" ) {
...but this didn't work either. Any help would be welcome!
======================
Sean Shrum
http://www.shrum.net
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: testing a non-existant hash entry...how to handle
by busunsl (Vicar) on Mar 01, 2002 at 09:19 UTC | |
by S_Shrum (Pilgrim) on Mar 01, 2002 at 09:58 UTC | |
|
Re: testing a non-existant hash entry...how to handle
by Ryszard (Priest) on Mar 01, 2002 at 09:31 UTC | |
by ropey (Hermit) on Mar 01, 2002 at 10:05 UTC | |
|
Re: testing a non-existant hash entry...how to handle
by PrakashK (Pilgrim) on Mar 01, 2002 at 15:08 UTC | |
|
Re: testing a non-existant hash entry...how to handle
by ton (Friar) on Mar 01, 2002 at 19:40 UTC |