title: Javascript not being called from hyperlink
body: <p>I am using Google Apps Script to create a web app that contains several hyperlinks. When a hyperlink is clicked, it is supposed to trigger an alert box (just filler code to see if JS function is being called). My hyperlinks are being generated using this javascript function:</p>
  
  <pre><code>function updateAlertList(results) {
  
      var div = document.getElementById('output');
      div.innerHTML = '';
  
      for (var i=0;i&lt;results.length;i++)
      { 
          div.innerHTML += '&lt;p&gt;&lt;a class="ra-button" href="javascript:void(0)" onclick="myJsFunc()"&gt;' + results[i].alertName + '&lt;/a&gt;&lt;/p&gt;';
      }
  }
  </code></pre>
  
  <p>and the JS function that generates the alert is:</p>
  
  <pre><code>function myJsFunc(){
      alert('this function was called');
  }
  </code></pre>
  
  <p>For some reason, only the LAST hyperlink in the list of hyperlinks will trigger the JS function called myJsFunc. Whenever I click on any of the other hyperlinks that are earlier in the list, the JS function is not called. When I look in the console in Chrome Developer tools, I see the error "Cannot read property 'plugin_dispatchEvent___' of undefined"</p>
  
  <p>Anybody know why the very last hyperlink in my list of hyperlinks works.. but the earlier ones don't?</p>