http://qs321.pair.com?node_id=93531


in reply to cgi: Grabbing Multiple input values

I think the problem may be with your naming scheme. As opposed to naming the select box something like "input", try naming it:
input[]; For the full example: <form> <select NAME="input[]" SIZE=3 MULTIPLE> <option VALUE="opt1">option1 <option VALUE="opt2">option2 <option SELECTED VALUE="opt3">option3 </select> </form>
And then when it gets to your Perl script, you can treat it as an array. Otherwise, your Perl script really does only see it as one value.
-Eric

UPDATE Okay, maybe it's time to kick myself for having a PHP background before I came around to the Perl world :-)

However, what would the proper method be in this scenerio -- If I used HTML::Template to build my template, and CGI.pm to process them.. in that case, what would be the proper thing to name the SELECT element?
a. <select name="myname" multiple> b. <select name="myname[]" multiple>
Thanks! :-)