The code is supposed to disable a group of checkboxes. There are two classes of checkbox, if I click on one, it disables the other. The problem is if I change my mind and want to unchoose (uncheck), it does not allow me to uncheck.
$(".single-checkbox").click(function(){
if ($(this).prop("checked", "checked")) {
$('.deleteDone').prop('disabled', true);
} else {
// $(this).prop("unchecked", "unchecked")
// $('.deleteDone').prop('disabled', false);
// $(".single-checkbox").prop("checked", false);
}
});
I have tried various things in the else part of the statement but no luck. Would you have any ideas? There are a couple of questions on unchecking checkboxes and i tried variations in my code but no luck.
Any help appreciated.