Skip welcome & menu and move to editor
Welcome to JS Bin
Load cached copy from
 
<!DOCTYPE html>
<html>
<head>
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.8/jquery.min.js"></script>
<meta charset=utf-8 />
<title>JS Bin</title>
</head>
<body>
  <div>
<table id="ContentPlaceHolder1_CheckBoxList1" class="cbxlMulti">
  <tbody>
    <tr>
      <td>
        <input id="ContentPlaceHolder1_CheckBoxList1_0" type="checkbox" name="ct100$ContentPlaceHolder1$CheckBoxList1$0" value="AAAA">
        <label for="ContentPlaceHolder1_CheckBoxList1_0">AAAA</label>
      </td>
    </tr>
    <tr>
      <td>
        <input id="ContentPlaceHolder1_CheckBoxList1_1" type="checkbox" name="ct100$ContentPlaceHolder1$CheckBoxList1$1" value="BBBB">
        <label for="ContentPlaceHolder1_CheckBoxList1_1">BBBB</label>
      </td>
    </tr>
    <tr>
      <td>
        <input id="ContentPlaceHolder1_CheckBoxList1_2" type="checkbox" name="ct100$ContentPlaceHolder1$CheckBoxList1$2" value="BBBB">
        <label for="ContentPlaceHolder1_CheckBoxList1_2">BBBB</label>
      </td>
    </tr>
  </table>
</div>
<div>
<input type="checkbox" ID="CheckBox1"  CssClass="cbxSingle" value="XXXX" />
</div>
</body>
</html>
 
    $(function(){
        $("input[type=checkbox]").click(function () {
          var a= $("input[id^='ContentPlaceHolder1_CheckBoxList1']:checkbox:checked");
          
          if($(a).length > 0){
            $('#CheckBox1').attr('checked','checked');           
           }
          else
            $('#CheckBox1').removeAttr('checked');
        });
    });
Output

You can jump to the latest bin by adding /latest to your URL

Dismiss x
public
Bin info
anonymouspro
0viewers