Re: Apache2::Request param repetitions

Ted <[email protected]>
Newsgroups gmane.comp.apache.apreq
Message-ID <[email protected]>
That's true, I could do that, but my aim is to have a general purpose
form reader.  I want to loop through all form elements and load
up a hash for processing later.  I could put all encountered param
names in a hash prior to processing, to eliminate the problem, but
thought the issue was worth mentioning.

Thanks,
Ted

Jonathan wrote:

> i think its because of the way that you're looping it...
>
> the browser sends
>     user_status= active
>     user_status= inactive
>     user_status= deleted
> and your loop is picking up all 3
>
> if you call param('user_status') you should just get an array of  
> ['active','inactive','deleted']
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.