title: Run Javascript on Image Click
body: <p>I have the following graphical button on my site:</p>
  
  <pre><code>&lt;a href="#" class="addto_cart_btn"&gt;
    &lt;span id="btn_text"&gt;Click here to add to cart now&lt;/span&gt;             
  &lt;/a&gt;
  </code></pre>
  
  <p>I want to run a specific javascript script when clicked (current value #) to run some javascript - the javascript code essentially generates a popup iFrame with additional content in it.</p>
  
  <p>What is the best approach for achieving this?</p>