How to mark an input radio when clicking on a DIV?

0

The question is self explanatory.

I have a form with 3 divs, each div has a

asked by anonymous 13.03.2018 / 18:14

1 answer

1

Enclose your image with label and assign it to id of radio that already solves your problem:

<input name="teste" type="radio" id="test1" />
<label for="test1">
    <img src="path-da-imagem" />
</label>
    
13.03.2018 / 18:19