title: onunload Ajax function not working in Chrome
body: <p>I am developing an app that needs to store updated data in a database when the user leaves the page. To do this I have bound a Ajax function to the "onunload" event of the page. This works in every browser except Chrome. I have also tried "onbeforeunload" but the result is the same.</p>
  
  <p>I suspect it something to do with Chrome being over zealous in it's security. When trying to test the event I found it was blocking the alerts I put in to see if function was even being called and also get the error "Usafe JavaScript attempt to access frame with URL ... Domains, protocols and ports must match." The postback is going to a page within the same domain.</p>
  
  <p>Can anyone shed any light on this or possibly provide me with a work around?</p>