#14559 closed bug (notabug)
bug
Reported by: | Owned by: | ||
---|---|---|---|
Priority: | undecided | Milestone: | None |
Component: | unfiled | Version: | 1.9.1 |
Keywords: | Cc: | ||
Blocked by: | Blocking: |
Description
the function
$( window ).unload(function() {
alert( "Bye now!" );
});
can not work on Chrom
Change History (4)
comment:1 Changed 9 years ago by
comment:2 Changed 9 years ago by
Resolution: | → notabug |
---|---|
Status: | new → closed |
Thanks for the report! As axl.jq said, it's a documentation issue, not the jQuery one. I reported it there: https://github.com/jquery/api.jquery.com/issues/388
Note: See
TracTickets for help on using
tickets.
The event isn't intended to do such things, it's only to show a *confirmation message*. Chrome is blocking old behavior to run specific code onunload. As it should always be.
Use it this way: http://stackoverflow.com/a/3464537/1670956
jQuery guys, you should remove outdated examples at http://api.jquery.com/unload/ since I suppose all browsers will follow the Chrome behavior.