vendredi 11 décembre 2020

Check Boxes Select And disable other Check Boxes Worked. But Un Check Not Working

I Used The Code This Code for multi select condition . but when condition meet other checkboxes not select its perfect. but the uncheck not working then any solution?

<script>
 
$(":checkbox[class='.wapf-input']").change(function(){
  if ($(":checkbox[class='.wapf-input']:checked").length == 2)                                              
   $('.wapf-swatch').prop('disabled', true);  
  else                                                     
   $('.wapf-swatch').prop('disabled', false); 
});
</script>



Aucun commentaire:

Enregistrer un commentaire