title: How do you do a mandatory checkbox in a form?
body: <p>I need a checkbox, where you move from one page to another after clicking the box. The checkbox should be required, given that you've read the terms and conditions link next to it.</p>
  
  <p>I'm only half sure how to do this, something like this:</p>
  
  <pre><code>&lt;input type="checkbox" value="confirm_prepay_terms" name="confirm_prepay_terms" align="middle" /&gt;
  </code></pre>
  
  <p>with Jquery:</p>
  
  <pre><code>&lt;script type="text/javascript" language="javascript"&gt;
  $(document).ready(function() {
          if ($('form#prepay input:checkbox', 'confirm_prepay_terms').is(':checked') {
                  return true;
          } else {
              $('#confirm_terms_hint').text('Please try again - you need to check the box to move on');
              $('#confirm_terms_hint').css('font-weight', 'strong');
              return false;
          }
  }
  &lt;/script&gt;
  </code></pre>
  
  <p>At the moment though, I can't view the checkbox at all on the page, so perhaps my HTML is incorrect?</p>
  
  <p>Hope you can help.</p>