title: Javascript check box checked for specific id
body: <p>All I want to know is that how to check those boxes only which trues my if condition right now all the check boxes are getting checked.... please help....</p>
  
  <pre><code>for ( var t = 0; t &lt; contactsJsonArray.length; t++) {
      for ( var j = 0; j &lt; optionresponse.length; j++) {
          if (optionresponse[j].contactid == contactsJsonArray[t].id) {
              $(".checkHit").each(function() {
                  this.checked = true;
              }); 
          }
      }
  }
  </code></pre>