One could simply deprecate the onunload (but still support it) and create a new version onDestroy that is called as well. Old apps won't know about onDestroy so it will be harmless and won't break them. New apps simply don't need to implement onunload and will use onDestroy. If you change onbeforeunload you will have compatibility issues with all those pages that use it now.
From: Giovanni Campagna [mailto:[email protected]] Sent: Tuesday, January 06, 2009 12:37 PM To: Shropshire, Andrew A; [email protected] Subject: Re: Proposal: Detecting when the user leaves a page due to hitting the back button or typing in a URL or going to a favorite 2009/1/6 Shropshire, Andrew A <[email protected]> These pages deserve to be broken :) Unfortunately, the user doesn't know that little fact. Instead it knows that with IE6 or FF2 or Opera9.5 it worked, with the latest browser it doesn't. And will complain with the browser vendor, and will keep the old browser (thus preventing any innovation) Giovanni
