Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

passing option multiple values

Status
Not open for further replies.

Greenster

Programmer
Jan 14, 2002
30
0
0
GB
Please help,

I have a simple form
<form action=&quot;myscript.php&quot; methode=&quot;GET&quot; name=&quot;myform&quot;>
<select name=&quot;myselect&quot; multiple>
<option value=1>Option 1</option>
<option value=2>Option 2</option>
<option value=3>Option 3</option>
<option value=4>Option 4</option>
</select>

When I select more than one value and do a <? die(print_r($HTTP_GET_VARS)) ?> it only ever contains ONE of the values??? What am I doing wrong, how can I pass multiple values???

Any help would be much apreciated

{Greenser}
 
Add [] to the SELECT's name to get the input stored in an array:

<SELECT NAME=myselect[] MULTIPLE> Matt
matt@paperlove.org
If I can help, I will.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top