Tutorials

KodeKite Tools

HTML
Flexbox
SVG
Canvas
HTML Tutorial

More


HTML Select Element
Select Element

Select element is a menu element and is used to display list of items. It can display more than one item means there is no limit for items to display and items can be displayed by option element in list form.

Syntax

<select>
<option>Item 1</option>
<option>Item 2</option>
<option>Item 3</option>
</select>


You can use select and option elements any where within an HTML document.


Example


Select and Option are pair tags and output of both is item menu like you can see in above example.


Practice Task

Open notepad or any other text editor, follow the following points.


  • Create a form
  • Create item list

save file with name task.html or task.htm and then open it using any browser and see results.


Solution


Don't forget select and option are non empty elements which means they always come in pair.