Form field allows multiple choices...HOW to pass variables?
Posted: Thu Apr 08, 2004 9:10 pm
I have a form that has a list field that needs to allow the user to make multiple selections. This form action calls a PHP page.
for example...
If (on the PHP page) I use
Only the LAST one of the choices is echoed.
How do I pass ALL the choices as variables to my PHP page??
--Tim
for example...
Code: Select all
<select name="options" size="5" multiple>
<option value="dp">ABS</option>
<option value="x>">CD Player</option>
<option value="Tm">Climate Control</option>
<option value="CU">Cruise Control</option>
<option value="b^">Moon Roof</option>
</select>Code: Select all
<?php
$options=$_POST['options'];
echo $options;
?>How do I pass ALL the choices as variables to my PHP page??
--Tim