in reply to Hash equivalent of wantarray?

You probably want to enforce scalar context on the expression.

my %hash = ( 'formval1' => scalar gParam('formval1'), 'formval2' => scalar gParam('formval2') );

See also Want.pm.

--
<http://dave.org.uk>

"The first rule of Perl club is you do not talk about Perl club."
-- Chip Salzenberg