How capture event for browser closing in web applications

web-applications

When a web application running and on close the browser window then which event raise?

Best Answer

onunload is the event raised when closing the browser window.

How ever this event isn't fired only when closing the browser, that's just one case.