Select, Textarea, and Buttons
Beyond input elements, forms use select dropdowns, textareas for longer text, and various button types.
Select Dropdowns
Loading HTML Playground...
Select elements:
<select>- Dropdown container<option>- Individual choicesvalue- Submitted value (text shown if empty)
Option Groups
Loading HTML Playground...
<optgroup> groups related options with a label.
Multiple Select
Loading HTML Playground...
Attributes:
multiple- Allow multiple selectionssize- Visible options without scrolling
Textarea
Loading HTML Playground...
Textarea attributes:
rows/cols- Size (better to use CSS)placeholder- Hint textmaxlength- Character limit- Content between tags is default value
Button Types
Loading HTML Playground...
Button types:
submit- Submits the form (default)reset- Clears all fieldsbutton- No default action
Input vs Button Submit
Loading HTML Playground...
Datalist for Autocomplete
Loading HTML Playground...
Datalist provides autocomplete suggestions:
- Linked via
listattribute - User can type custom values
- Options appear as suggestions
Output Element
Loading HTML Playground...
Exercise: Create Feedback Form
Create a feedback form with select, textarea, and buttons:
Loading HTML Exercise...
These elements provide rich user input options beyond simple text fields!

