title: Question regarding jQuery click() function
body: <pre><code>    $('document').ready(function(){
          $('[name=mycheckbox]').live('click', function(){
              if($(this).is(':checked'))
              {
                  alert('it is checked');
              }
              else
              {
                  alert('it is not checked');
              }
          });
  
          $('[name=mycheckbox]').click();
      });
  </code></pre>
  
  <p><strong>If the checkbox is checked</strong> and you click it, the alert box says, "it is not checked", but when the page runs and the click event is fired (<strong>with the checkbox checked</strong>), the alert box says, "it is checked". Why? Is the state of the checkbox not effected by the click event? Is it mousedown that changes the state?</p>