PDA

Click to See Complete Forum and Search --> : how can i tell if a window is already open


tina104291325
Sep 18th, 2002, 09:29 AM
i use the following code in all my pages to open a new IE window

m_PL = window.open('../flash/player.html','m_PL','directories=0,height=85,width=293,left=0,menubar=0,resizable=0,scrollbars=0,tit lebar=0,toolbar=0,top=0')


how can i tell if that window is already open so the other pages won't reload the same page

msimmons
Sep 18th, 2002, 04:34 PM
if (m_PL){
//the window is open
}else{
//the window is not open
}


one thing to remember when using this method is that you have to set m_PL = 0 in the onUnload of the window so that the code doesn't think the window is there when it is not.

Hope that helped,
Michael