Posted By

delineo on 12/03/10


Tagged

check jquery checkbox all


Versions (?)

asp:checkbox check all checkboxes using jQuery


 / Published in: VB.NET
 

  1. // Checks all individual checkboxes
  2. $(".checkAreaAll").children("input").click(function () {
  3.  
  4. $(".checkArea").children("input").attr('checked', $(".checkAreaAll").children("input").is(':checked'));
  5.  
  6. });
  7.  
  8. // unchecks the check all checkbox when one individual checkbox is unchecked
  9. $(".checkArea").children("input").click(function () {
  10.  
  11. $(".checkAreaAll").children("input").attr('checked', false);
  12.  
  13. });

Report this snippet  

You need to login to post a comment.