issue in jquery radio button selection
- by Sri
I am not much more flexible with jquery. I have some li tags and for each li tag, I have one input tag of type radio like:
<li><input type='radio' value='cool' name='radiooption' id='2'>2</li>
<li class='answered'><input type='radio' name='radiooption' value='cool1' id='3'>3</li>
<li><input type='radio' value='cool' name='radiooption' id='4'>4</li>
<li><input type='radio' value='cool' name='radiooption' id='2'>5</li>
Now by jquery how to add checked="checked" for radio button which is under li tag having class='answered'?
Please guide me.