HTML - Proper way of using radio button

0 votes
188 views
added Mar 21, 2019 in HTML by LC Marshal Captain (25,790 points)
<!--'name' attribute will keep the radio button work as a group. -->

<!--group 1-->
<input type="radio" name="group1" />
<input type="radio" name="group1" /> 


<!--group 2-->
<input type="radio" name="group2" />
<input type="radio" name="group2" />

 

lazacode.org - Malaysia's programming knowledge sharing platform, where everyone can share their finding as reference to others.
...