> -----Original Message-----
> From: Tatsuhiko Miyagawa [mailto:[EMAIL PROTECTED]]
> 
> There is some inconsistency between CGI.pm and Apache::Request's
> param() method, especially in handling of multivalued parameter.
> 
>   $q = CGI->new;
>   $q->param(foo => qw(a b c));
>   @foo = $q->param('foo');         # ('a', 'b', 'c')
>   $q->param(bar => [ qw(a b c) ]);
>   @bar = $q->param('bar');         # (['a', 'b', 'c'])
> 
>   $r = Apache::Request->new(Apache->request);
>   $r->param(foo => qw(a b c));     # die with an error
>   $r->param(bar => [ qw(a b c) ]);
>   @bar = $r->param('bar');         # ('a', 'b', 'c')
> 
> Am I the only one who wants consistency between the two?

I guess so. Your above is equivalent to:

  $r->param(foo => 'a', b => 'c');

(foo => qw(a b c)) doesn't do what it looks like it does, and that's a bad
thing.

Matt.

_____________________________________________________________________
This message has been checked for all known viruses by Star Internet
delivered through the MessageLabs Virus Scanning Service. For further
information visit http://www.star.net.uk/stats.asp or alternatively call
Star Internet for details on the Virus Scanning Service.

Reply via email to