Using the HTML 'label' tag with radio buttons

前端 未结 7 549
暗喜
暗喜 2020-12-28 12:07

Does the label tag work with radio buttons? If so, how do you use it? I have a form that displays like this:

First Name: (text field)
Hair Col         


        
7条回答
  •  醉酒成梦
    2020-12-28 12:26

    You can use the aria-role="radiogroup" to associate the controls without using a

    . This is one of the techniques suggested by WCAG 2.0.

    What is your profession?

    If dual-classed, selected your highest leveled class

    However, I noticed that using this technique the WebAim Wave tool to give a warning about a missing

    , so I'm not sure what AT support for this is like.

提交回复
热议问题