javascript - Detect browser or tab closing -
is there cross-browser javascript/jquery code detect if browser or browser tab being closed, not due link being clicked?
if correctly, want know when tab/window closed. well, afaik way in javascript
detect kind of stuffs onunload
& onbeforeunload
events.
unfortunately (or fortunately?), events fired when leave site on link
or browsers button. best answer can give, don't think can natively detect pure close
in javascript. correct me if i'm wrong here.
Comments
Post a Comment