I am creating a web quiz application using PHP. Each question consists of a separate <label> and has 4 possible options using radio buttons so that the user can select his answer. The current HTML for one question looks like this:
<label for="349">What is my middle name?</label> <br> <input id="349" type="radio" value="1" name="349">Abe <br> <input id="349" type="radio" value="2" name="349">Andrew <br> <input id="349" type="radio" value="3" name="349">Andre <br> <input id="349" type="radio" value="4" name="349">Anderson <br>
I would like the user to be able to click on the text associated with the radio button. . Right now, the user can only click on the switch itself - which I consider a rather cumbersome task.
I read. It is not possible to select a specific selection of the radio button by clicking on the selection text , and the prompts indicate the creation of the for and id attributes matching labels. I did this and it still does not work.
My question: I would like to be able to click on the text of the <input type="radio"> object, and not just select the switch itself. I know that I read about this earlier, but cannot find a solution to my problem. Any help or suggestions are greatly appreciated!
html input css radio-button forms
Abundnce10 Oct 22 '11 at 23:17 2011-10-22 23:17
source share