Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:
Weirdness.... I take in a parameter and modify it. When I try to pass it on to another CGI, it doesn't pass....
use CGI qw/:standard/; use strict; my $cgi = new CGI; my $species = param('species'); $species = 'Not Rat'; print $cgi->header(), $cgi->start_html(), $species, $cgi->hidden( -name => 'species', -default=> $species, ), $cgi->end_html();
On screen it displays "Not Rat", but the value in my hidden field is "Rat". What gives? Is this a CGI.pm feature? I scanned the perldoc but didn't see anything like this, but I didn't know what exactly I was looking for....
|
---|
Replies are listed 'Best First'. | |
---|---|
Re: Can't modify variable received from CGI parameter
by menolly (Hermit) on Sep 09, 2003 at 00:29 UTC | |
Re: Can't modify variable received from CGI parameter
by benn (Vicar) on Sep 09, 2003 at 10:41 UTC | |
Re: Can't modify variable received from CGI parameter
by Anonymous Monk on Sep 09, 2003 at 13:54 UTC |