title: How can I capture form options on submit?
body: <p>How can I capture form options on submit?</p>
  
  <p>I have a plain html form which I can call a JavaScript function from on exit, But how do I capture the chosen option from the <code>&lt;select&gt;</code> element?</p>
  
  <p>Please see code below:</p>
  
  <pre><code> &lt;legend&gt;Administration:&lt;/legend&gt;
  &lt;script type="text/javascript"&gt;
    function handleIt(m){
        alert("hello");
        }
  
  &lt;/script&gt;
  &lt;/head&gt;
  &lt;body&gt;
    &lt;form action="javascript:handleIt(select.name)"/&gt;
    &lt;select name="num" required&gt;
    &lt;option value="1"&gt;Add Anouncment&lt;/option&gt;
    &lt;option value="2"&gt;Del Anouncment&lt;/option&gt;
    &lt;option value="3"&gt;Aprove &lt;/option&gt;
    &lt;option value="4"&gt;unAprove &lt;/option&gt;
    &lt;/select&gt; 
  &lt;input name="Anouncement" type="text" required&gt; 
    &lt;input name="Submit"  type="submit" value="Update"/&gt;
  &lt;/form&gt;
  </code></pre>