0

I wrote this simple script, and it's seems to work fine, but only once. I click div-container - the radio within gets checked. I click another div - another radio gets checked. But now, when I click the previous div again, the radio won't get checked.

Here's the code:

$('div').click(function () {
   $(this).find('input:radio').attr('checked', true);
});

And example: http://jsfiddle.net/aa7q6Lxy/1/

Thanks for suggestions!

Rory McCrossan
  • 331,213
  • 40
  • 305
  • 339
it1g
  • 1

0 Answers0