The below code works fine in IE8.
Here is my code:
window.onbeforeunload = function () {
return "Are you sure want to LOGOUT the session ?";
};
window.onunload = function () {
parent.logout();
};
But in IE9+
window.onbeforeunload
works and I am getting the alert.
But the window.onunload
is not working.
I also tried the Group Policies in Internet Explorer 9
to enable the Allow Internet Explorer 8 Shutdown Behavior
.For reference , click here
How to make the window.onunload
to work in IE9+ ?
Hope our stack users will help me.