Types of Labels


The "Holy Grail" (Karl Groves) easy to incorporate 'help' text!

<label for="date">Date: <input type="text" size="30" id="date"><br />
in form of mm/dd/yyyy

Will cause Voiceover and Safari to speak <label> twice. Voiceover/Safari only works properly with Explict labeling. - Scott O'hara


Explicit labels are the easiest way to ensure that most user agents can associate form prompts with the correct control.

<label for="date">Date: </label>
<input type="text" size="30" id="date" />


Implicit - Not Recommended!

Implicit labels are legal according to the spec.

<label>Date: <input type="text" size="30"></label>