On Sun, Jul 21, 2002 at 11:43:25AM -0400, WANDA HANSEN wrote:
> Is there a way to handle data gathered from a drop down menu that
> allows multiple selections using PHP?

Yes.  The way I normally do this is to use HTML that looks something

<select multiple='multiple' name='test[]'>
<option value='1'>Red</option>
<option value='2'>Green</option>
<option value='3'>Blue</option>

Now in your PHP program, you can access them all with something like:

foreach($_POST['test'] as $test) {
   echo "You selected $test<br />\n";

Jason Stechschulte
History books which contain no lies are extremely dull.

PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to