title: Binding an event handler to an HTML select.option
body: <p>I want to show a warning message if a user selects a specific option, but the warning isn't appearing. How can I modify my code so that this works correctly? Here is a <a href="http://fiddle.jshell.net/ndgnvetm/2/" rel="noreferrer">demo on jsFiddle</a> which reproduces the problem?</p>
  
  <p>HTML :</p>
  
  <pre><code>&lt;input type="text" id="mail_address"/&gt;
  &lt;select&gt;
      &lt;option value='google.com'&gt;google.com&lt;/option&gt;
      &lt;option onClick="warningaa()" value=''&gt;Don't send mail&lt;/option&gt;
  &lt;/select&gt;
  </code></pre>
  
  <p>JS:</p>
  
  <pre><code>function warningaa() {
      alert('If you choose this option, you can not receive any information');
  }
  </code></pre>