after making a call to window.open
i would like to detect when the popUp window is closed
i have a Close button on the screen
so onClick, it will detect
but if the user click on the Close in the titlebar,
my code doesnt account for that
i have given the window a name,
eg, newPopUp
and tried checking for the existence of the window
but it doesnt seem to work…..
eg. when opening the window
[CODE]window.open(‘pop21.htm’,’cam1′,’width=640,height=550,scrolling=no,titlebar=no’)
winClosed=true
top.frames[‘camera1’].location.href = “about:blank”
and closing
[CODE]function winClose() {
opener.top.camera1.location = ‘test21.htm’
window.close()
}
[CODE]if (winClosed==true && !cam1) {
top.camera1.location = ‘test21.htm’
}
the winClose function is fine
but it will not detect if the window is closed through the X on the titlebar