I'm trying to fire a change event for a selected group radio button but this event gets fired if I select an already selected radio button. Can I prevent this from happening?
$("input[type='radio']").mouseup(function(){
...
}).change(function(){
...
});
HTML
<label class="radio">
<input type="radio" name="optionsRadios" id="optionsRadios1" value="option1" checked>
Option one
</label>
<label class="radio">
<input type="radio" name="optionsRadios" id="optionsRadios2" value="option2">
Option two
</label>
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.