title: JQuery events and double firing?
body: <p>When I load JQuery dynamically with AJAX, elements with existing events fire multiple times. </p>
  
  <p>Basically I have one file called 'myjs.js' which hold All my JQuery and is included when the page is loaded therefore setting up events and such for elements. </p>
  
  <p>Now when a user triggers an event like posting a new comment, it sends off (via Ajax) the comment, then it returns a page with the new comment, edit comment, reply etc. Obviusly when <code>myjs.js</code> was first loaded it didn't create any events for the newly loaded elements. Therefore I include <code>myjs.js</code> in the page returned with AJAX.</p>
  
  <p>As the <code>myjs.js</code> has already been loaded with the page, when the Ajax page is returned with <code>myjs.js</code> included, it adds another event to the elements that have already been loaded with the page.</p>
  
  <p>I have already tried</p>
  
  <pre><code>$('*').unbind();
  </code></pre>
  
  <p>But this caused some strange effects.</p>
  
  <p>So any ideas on loading JQuery dynamically while not affecting any events which already exist for elements?</p>