title: Check if a check box is checked or not (js/jquery)
body: <p>I want to check if a certain check box is selected using JavaScript/jQuery.</p>
  
  <p>Here is the code I tried:</p>
  
  <pre><code>var a;
      if ($("#add_desc").checked == 1){
          a = "true";
      }else{
          a= "false";
      }
  </code></pre>
  
  <p>I have also tried:</p>
  
  <pre><code>var a;
      if ($("#add_desc").checked){
          a= "true";
      }else{
          a= "false";
      }
  </code></pre>
  
  <p>It always returns false once I alert the variable <code>a</code>.</p>
  
  <p>Any idea why it won't work for me? Am I doing it wrong? </p>
  
  <p>Thanks!</p>