in reply to Using CGI.pm params to make a DBI MySQL query

Whenever I need to interpolate a lot, I create a hash - just like the good ol' days:
my %field; for ( param() ) { $field{$_} = param($_); }
but I've also found that the more I use CGI.pm, the more my coding moves away from that method towards template thingies.

cLive ;-)

Replies are listed 'Best First'.
(ichimunki) Re x 2: Using CGI.pm params to make a DBI MySQL query
by ichimunki (Priest) on Oct 09, 2001 at 19:56 UTC
    And just to be on the safe side
    my %field; for ( qw/foo bar baz/ ) { $field{ $_ } = param( $_ ); }
    This way we are explicitly allowing the things we want, and can even build in error handling if the things we need aren't there.