Popup Error Message Example Summary
Common Features of All Examples
Feature | Markup | Description |
---|---|---|
Required control | required attribute |
|
Invalid value | aria-invalid attribute |
The aria-invalid attribute provides a means to communicate to assistive technology that the form field has an invalid value.
|
Invalid value awareness | role="status" attribute |
|
Referencing the Error Message
Example | Accessible Name |
Accessible Description |
Notes |
---|---|---|---|
1 |
label[for] element used to reference the controls label.
|
none | No information provided on the error message when focus is moved to the invalide form control. |
2 |
|
none | Error information is provided through the accessible name property. |
3 |
label[for] element used to reference the controls label.
|
aria-describedby attribute used to reference the error message.
|
Error information is provided through the accessible description property. |
4 |
label[for] element used to reference the controls label.
|
title attribute contains the error message content visible in the graphical rendering.
|
Error information is provided through the accessible description property. |
5 |
aria-labelledby attribute is used to reference both label and the error message.
|
none | Error information is provided through the accessible name property. |
6 |
|
none | Error information is provided through the accessible name property. |