I need to know if there is a onwindow.close() (or something like that) function that I can use coz I need to perform some function when the user closes the window
no idea if there's an onwindow.close() event to trap it , I doubt it exists. But you can however check the existance of the window and if it doesn't execute the funtion.
function checkPop() {
if (popup && !popup.closed) {
}
else {
}
}
setInterval("checkPop()",1000);
popup being the name you gave to the popup window ofcourse.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.