> It would still IMHO be much better to do something like:
>
> %cards = (
> 4 => {name => 'Visa'},
> 5 => {name => 'MasterCard'},
> 6 => {name => 'Discover'},
> 3 => {name => 'AmEx'},
> );
>
> foreach my $cardid (keys %cards) {
> foreach my $property (@props) {
> $data{$cardid}{$property} = $form->param($cardid."_".$property);
> }
> }
Now this is something I like :) As a matter of fact instead of using $data I
can re-use $cards, so I have a single unified structure, hodling names,
properties, totals and other things, all addressable by the primary hash key
$cardid. I really like it :)
Thanks
Peter
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>