(Site Identification)

'Eye' Focus: Web Support Tutorials

Forms: SELECT Boxes


The SELECT tag defines a field for display as a drop-down or a scrolling box.

(to Top) Examples:

When: SIZE="1" or
not specified.


When: SIZE="3" and
MULTIPLE defined.



Syntax: (skip code)

<label for="...">...</label><br>
<select id="..." name="..." size="...">
<option value="...">Option 1</option>
<option value="...">Option 2</option>
<option value="...">Option 3</option>
... Yadda, Yadda, Yadda ...
</select>

(to Top) Definitions


NAME:

The NAME identifies the field.

SIZE:

The SIZE defines the number of options that are to be displayed at one time.

MULTIPLE:

You can also permit multiple items to be selected if you so choose. By holding the control key while clicking on an item you can then select more than one item in the list. The third list example has MULTIPLE turned on where you can try this. The change in the code would look like this: (skip code)
<select name="name" size="3" multiple>


[Updated: Sunday, November 18, 2007]