[Catalyst] Insert Multiple rows

Andy Grundman andy at hybridized.org
Wed Dec 14 18:34:31 CET 2005


Will Smith wrote:
> Hi,
> Sorry to ask the question one more time.
>  
> How could I insert multiple rows? On the template I have input boxes of 
> the same name that allow user enter more than one value at a time, and 
> need to insert those into the db.
> Anyone could give me some guide or sample? Deeply appreciated
> ps: The moderators please do not get mad.

I think you're really asking how to get multiple values for form 
elements that have the same name:

my @values = $c->req->param('foo');	# array
my $values = $c->req->param('foo');	# array ref
my $values = $c->req->params->{foo};	# array ref

-Andy



More information about the Catalyst mailing list