This smells like bad design.
However, provided it is CGI, you can easily do:
# If I got you right and the variable in question was multivalue # (as you represented it with a Perl array): my ( $username, $path, @names ) = $cgi->param("names"); # to geht what you need for the following: my @value; # will contain the values. foreach my $i ( 0 .. $#names ) { my $combined_name = $username . "-" . $names[$i]; # build the key $value[$i] = $cgi->param("$combined_name"); # fetch the valu +e }
Update: Code rewritten as foreach loop
Cheerio, Sören
In reply to Re: Getting back values of an array of names reurned by CGI when the names are variables
by Happy-the-monk
in thread Getting back values of an array of names reurned by CGI when the names are variables
by learner
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |