Ordered List (OL) in a Form

The reason for this page is used to show that if you place form elements in an un-ordered list or an ordered list screen readers will tell you how many items are in the list.

There is no “Submit” button for this form, since it‘s an example of an un-order list in a fieldset.

Personal Information

Below is the code that was used to create this form.

<form>
<fieldset>
<legend>Personal Information</legend>
<ol>
<li>
<label for="first_name">First Name</label>
<input type="text" name="first_name" id="first_name" />
</li>
<li>
<label for="last_name">Last Name</label>
<input type="text" name="last_name" id="last_name" />
</li>
<li>
<label for="company">Company</label>
<input type="text" name="company" id="company" />
</li>
<li>
<label for="title">Title</label>
<input type="text" name="title" id="title" />
</li>
</ol>
</fieldset>
</form>