Re: how to create multiple selects within php
| From: | John Nichel | Date: | Mon, 18 Oct 2004 14:14:46 +0000 |
| Subject: | Re: how to create multiple selects within php | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-199722@lists.php.net to get a copy of this message | ||
bruce wrote:
hi... i can create a form with a single select by something like: <form> <select name='foo'> <option val='1'>fff</option> <option val='2'>aaa</option> </select> <input > </form> however, i need to know how to create a multiple menu/list within a single form.Not sure exactly what you're asking here, but I think this may be it... If you want multiple select, you need your select tag to look as such... <select name="foo[]" multiple> On the page that the form is submitted too, the selections will be in an array ($_POST['foo']). -- John C. Nichel ÜberGeek KegWorks.com 716.856.9675 john@kegworks.com