title: TypeError: param.toElement is undefined
body: <p>Hey all I have the following code that's a mix of Prototype JS and Jquery:</p>
  
  <pre><code>var oldZindex = 0;
  var theClickID = null;
  
  UIProgressButton.prototype._initEvents = function() {
      var self = this;
      this.button.addEventListener( 'click', function(param) {
          $('#overlay').css({'visibility':'visible'});
          theClickID = $('button[data-id="' + param.toElement.attributes[1].value + '"]').parent().attr('id');
          oldZindex = $('#' + theClickID).css('z-index');
      });
  }
  </code></pre>
  
  <p>This code works just fine in a Chrome Browser but seems to throw the error of:</p>
  
  <blockquote>
    <p>typeerror param.toelement is undefined</p>
  </blockquote>
  
  <p>In FireFox.... How would I go about fixing this issue since I know for a fact that it does work since its working in Chrome just fine?</p>