---
url: "https://www.w3.org/WAI/WCAG22/Techniques/html/H91"
titulek: "H91: Using HTML form controls and links | WAI | W3C"
h1: "Technique H91:Using HTML form controls and links"
popis: ""
jazyk: "en"
kanonicka: ""
drobecky: []
zdroj: "live"
wayback_snapshot: ""
stazeno: "2026-09-14 05:32:09"
znaku: 8318
slov: 1219
kodovani: "utf-8"
sha256: "f1f11ec625a907f842c92cc5d19d4599cf49b9556abf7d7ca8ba011f5fa7738e"
---
# Technique H91:Using HTML form controls and links
## About this Technique
This technique relates to:
- [2.1.1 Keyboard](https://www.w3.org/WAI/WCAG22/Understanding/keyboard) ( **Sufficient** when used for ensuring keyboard control)
- [4.1.2 Name, Role, Value](https://www.w3.org/WAI/WCAG22/Understanding/name-role-value) ( **Sufficient** when used with [G108: Using markup features to expose the name and role, allow user-settable properties to be directly set, and provide notification of changes](../general/G108) )
This technique applies to HTML form controls and links.
Techniques are examples of ways to meet Web Content Accessibility Guidelines (WCAG). They are **not required** to meet WCAG. Content can satisfy the normative requirements of WCAG even if it does not use any of the documented techniques. See [About WCAG Techniques](https://www.w3.org/WAI/WCAG22/Techniques/about).
## Description
The objective of this technique is to use standard HTML form controls and link elements to provide keyboard operation and assistive technology interoperability of interactive user interface elements.
User agents provide the keyboard operation of HTML form controls and links. In addition, the user agent maps the form controls and links to an accessibility API. Assistive technologies use the accessibility API to extract appropriate accessibility information, such as role, name, state, and value, and present them to users. The role is provided by the HTML element, and the name is provided by the text associated with that element. Elements for which values and states are appropriate also expose the values and states via multiple mechanisms.
In some cases, the text is already associated with the control through a required attribute. For example, submit buttons use the `button` element text or image `alt` attribute as the name. In the case of form controls, `label` elements; the `aria-label` or `aria-labelledby` properties; or the `title` attribute are used.
## Examples
### Example 1: Links
User agents provide mechanisms to navigate to and select links. In each of the following examples, the role is "link" because the `a` element has an `href` attribute. An `a` element without an `href` isn't a link. The link's value is the URI in the `href` attribute.
#### Link example A
In example A, the name is the text inside the link, in this case "Example Site".
```
Example Site
```
#### Link example B
In example B of an image inside a link, the `alt` attribute for the image provides the name.
```
```
#### Link example C
In example C, some assistive technology will not automatically insert a space character when concatenating the image's `alt` text and the text of the link. If the text should not be concatenated without a space, it is safest to insert a space between the image and the adjacent word so that words will not run together.
```
Text
```
### Example 2: Buttons
There are several ways to create a button in HTML.
#### Buttons example A
In example A, the text contained in the `button` element, in this case "save", gives the button its name. There is no value.
```
```
#### Buttons example B
Example B uses the `value` attribute, in this case "Save", "Submit", or "Reset" as the name.
```
```
#### Buttons example C
Example C uses the `alt` attribute, in this case "save", as the name.
```
```
#### Buttons example D
Example D clarifies how the user agent determines the name if the author specifies both the `alt` and `title` attributes of the input element. In this case, the user agent uses the `alt` attribute ("Save") and ignores the `title` attribute.
```
```
### Example 3: Text Input
#### Text Input example A
In example A, the input field has a role of "editable text". The `label` element is associated to the `input` element via the `for` attribute which references the `id` attribute of the `input` element. The name comes from the `label` element, in this case, "Type of fruit". Its value comes from its value attribute, in this case "bananas".
```
```
#### Text Input example B
In example B, the input field has the same role as example A, but the value is the empty string and the field gets its name from the `aria-label` property.
```
```
### Example 4: Checkbox
This example has a role of `checkbox`, from the `type` attribute of the `input` element. The `label` element is associated with the `input` element via the `for` attribute which refers to the `id` attribute of the `input` element. The name comes from the `label` element, in this case "cheese". Its state can be `checked` or `unchecked` and comes from the `checked` attribute. The state can be changed by the user's interaction with the control.
```
```
### Example 5: Radio Buttons
This example has a role of "radio button" from the `type` attribute on the `input` element. Its name comes from the `label` element. Its state can be `checked` or `unchecked` and comes from the `checked` attribute. The state can be changed by the user's interaction with the control.
```
```
### Example 6: Radio Fieldset
The radio `fieldset` has a role of "grouping". The name comes from the `legend` element.
```