Answer the question
In order to leave comments, you need to log in
Why is the checked attribute not being set?
Added a spoiler, by clicking on the label, a div opens. Stopped checking radio.
in a loop, loaded with ajax
.spoiler {display:none;}
<div class="box">
<label class="spoiler_links">
<input class="linkradio" type="radio" name="postamat">
</label>
<div class="spoiler"><?=$arr['spoiler'];?></div>
</div>
$(document).on('click','.spoiler_links',function (e) {
$("div[class^='spoiler']").hide('normal');
$(this).parent().children('div.spoiler').toggle('normal');
return false;
});
$('.linkradio').attr('checked',true);
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question