title: jQuery: Check if button is clicked
body: <p>I have two buttons in a form and want to check which one was clicked.
  Everything works fine with radioButtons:</p>
  
  <pre><code>if($("input[@name='class']:checked").val() == 'A')
  </code></pre>
  
  <p>On simple submit button everything crash.</p>
  
  <p>Thanks!</p>