HTML Dog

Skip to navigation

HTML Tag: optgroup

Option group. Defines a group of option elements in a select form field.

Required Attributes

Optional Attributes

Example


<select name="catsndogs">
	<optgroup label="Cats">
		<option>Tiger</option>
		<option>Leopard</option>
		<option>Lynx</option>
	</optgroup>
	<optgroup label="Dogs">
		<option>Grey Wolf</option>
		<option>Red Fox</option>
		<option>Fennec</option>
	</optgroup>
</select>