Labels and forms
I have a question about labels and forms:
My Senior IT Specialist put up a label. However, the United States Access Board said that it is not that simple.
According to the Access-Board:
1) If the form field is also inside the LABEL start end tags, we are done.
2) If it is outside the LABEL start end tags, (which is often the case with layout tables)
then <label>x</label> is the requried format
My Senior IT Specialist put up the format:
<label>x
</label>
But verfieid in an e-mail that the form suspect is outside Scenario #2.
The Access-Board willl only pass the existing form if it was inside.
Are there any workaround's to this?
My Senior IT Specialist put up a label. However, the United States Access Board said that it is not that simple.
According to the Access-Board:
1) If the form field is also inside the LABEL start end tags, we are done.
2) If it is outside the LABEL start end tags, (which is often the case with layout tables)
then <label>x</label> is the requried format
My Senior IT Specialist put up the format:
<label>x
</label>
But verfieid in an e-mail that the form suspect is outside Scenario #2.
The Access-Board willl only pass the existing form if it was inside.
Are there any workaround's to this?
| Code: |
|
<label for="message">Message</label> <input id="message" type="text" /> |
I am trying to suggest to my Senior IT Specialist and my supervisor
<label for="message>Message</label>
<input type="text" id="message" for="mesage">
The have rejected this format
They have used
<label for="message">
<input type="text">
</label>
The U.S. Access-Board says for outside forms the first template is required.
But, they have used the second template.
It will not validate.
<label for="message>Message</label>
<input type="text" id="message" for="mesage">
The have rejected this format
They have used
<label for="message">
<input type="text">
</label>
The U.S. Access-Board says for outside forms the first template is required.
But, they have used the second template.
It will not validate.
The U.S. Access-Board gave me a form based template to work with.
I will wait and see if they accept or reject it.
I will wait and see if they accept or reject it.
If you are using HTML, then form labels must be either like this (explicit labelling):
Or like this (implicit labelling):
These are both correct. The first way is perhaps more logical, since the label text is separate from the control it is labelling. The second way uses less markup and is probably easier to generate due to having no for+id attributes.
The first way is well-suited to checkboxes and radio boxes, since they don't have text content. The second way is well-suited to <textarea> and <select> since they can have a lot of content.
Sometimes implicit labelling can improve the interface, such as this example:
As opposed to the explicitly labelled version:
Since the value of the <input> is a logical part of its own labelling text, implicit labelling produces a more natural experience for this example.
(EDIT) Corrected </label> tag.
Last edited by Ben Millard on 24 Dec 2009 01:24 pm; edited 1 time in total
| Code: |
| <label for="message">Label text here:</label> <input id="message">
|
| Code: |
| <label>Label text here: <input></label> |
The first way is well-suited to checkboxes and radio boxes, since they don't have text content. The second way is well-suited to <textarea> and <select> since they can have a lot of content.
Sometimes implicit labelling can improve the interface, such as this example:
| Code: |
| <label>Stay logged in for <input value="30"> minutes.</label> |
| Code: |
| <label for="timeout">Stay logged in for this many minutes:</label> <input id="timeout"> |
(EDIT) Corrected </label> tag.
Last edited by Ben Millard on 24 Dec 2009 01:24 pm; edited 1 time in total
The document is in the process of being fixed. However, I have a new question.
Can implicit forms meet WCAG 1.0 checkpoint 10.2 and/or 12.4
Until user agents support explicit associations between labels and form controls, for all form controls with implicitly associated labels, ensure that the label is properly positioned. [Priority 2]
The label must immediately precede its control on the same line (allowing more than one control/label per line) or be in the line preceding the control (with only one label and one control per line) Checkpoint 10.2
12.4 Associate labels explicitly with their controls. [Priority 2]
For example, in HTML use LABEL and its "for" attribute. (Checkpoint 12.4)
Can implicit forms meet WCAG 1.0 checkpoint 10.2 and/or 12.4
Until user agents support explicit associations between labels and form controls, for all form controls with implicitly associated labels, ensure that the label is properly positioned. [Priority 2]
The label must immediately precede its control on the same line (allowing more than one control/label per line) or be in the line preceding the control (with only one label and one control per line) Checkpoint 10.2
12.4 Associate labels explicitly with their controls. [Priority 2]
For example, in HTML use LABEL and its "for" attribute. (Checkpoint 12.4)
| 508 wrote: |
| Can implicit forms meet WCAG 1.0 checkpoint 10.2 and/or 12.4 |
They can meet 10.2, providing that the labels are properly positioned.
They can only meet 12.4 provided that they are explicitly labelled as well as being implicitly labelled.
In other words, to achieve WCAG 1.0, explicit labelling is mandatory; implicit labelling is not.
Jack Pickard The Pickards Information Services| Blog | Twit


