title: One form, multiple submit buttons and submit links
body: <blockquote>
    <p><strong>Possible Duplicate:</strong> <br/>
    <a href="https://stackoverflow.com/questions/48/multiple-submit-buttons-in-an-html-form">Multiple submit buttons in an HTML form</a></p>
  </blockquote>
  
  
  
  <p>I have web form with multiple submit buttons. To determine which button was pressed, each has a different name, like so:</p>
  
  <pre><code>&lt;input type="submit" name="foo" value="Foo Foo"&gt;
  </code></pre>
  
  <p>On the form there are also normal links that act as submit buttons, like so:</p>
  
  <pre><code>&lt;a href="" onclick="parentNode.submit();return false;"&gt;
  Bar
  &lt;/a&gt;
  </code></pre>
  
  <p>How do I also distinguish between the links being used as submit buttons?</p>
  
  <p><br /><br /></p>
  
  <p>I am not sure if this is relevant: <br />
  Here is the start of the form</p>
  
  <pre><code>&lt;form action="foobar" method="post" enctype="multipart/form-data"&gt;
  </code></pre>
  
  <p>I am using Flask (a micro-framework based on Werkzeug) which uses Python (2.6 in this case).</p>