Adding an aria-labelledby attribute would require WP Accessibility to be able to identify that a given piece of unassociated content was intended as labelling information for a field, which isn’t something it’s possible to do. (If it was, screen readers would already be doing that!)
What is the context in which you want to use aria-labelledby in a form? The reasonable occasions for that to be used in a form are pretty limited.
Hi Joe,
I’m using WPforms and I’m getting errors in my WAVE tool that say:
Errors Multiple form labels
What It Means
A form control has more than one label associated with it.
Why It Matters
A form control should have at most one associated label element. If more than one label element is associated to the control, assistive technology may not read the appropriate label.
It doesn’t appear that wpforms allows me to add any additional aria tags (my thought is aria tags would resolve those errors). Am I incorrect?
Thanks,
Jay
No, ARIA attributes won’t resolve those errors. They *might* clarify what the lable is intended to be for a given field, but they won’t resolve the fact that the field has more than one label assigned, and that assistive technology will have to choose how to read the information for the field, since the duplication makes it ambiguous.
Better would be to change the HTML so that only one label is used.