more useful options | |
PerlMonks |
Re: Input arrays to CGIby Jazz (Curate) |
on Jul 24, 2002 at 03:08 UTC ( [id://184680]=note: print w/replies, xml ) | Need Help?? |
If you're using CGI.pm (and you should be when doing most CGI work), you can retrieve the list of all CGI parameters by using: my @fields = param; Or you can access a value individually by using: my $single_item = param( 'item[123]' ); Or print out all params and their values by using: print join br, map { "$_ = " . param( $_ ) } param(); If you're not using CGI.pm, you can do so easily by adding use CGI qw/ :standard /; at the top of your program. Documentation for CGI.pm is here.
In Section
Seekers of Perl Wisdom
|
|