popWindow=null; function open_window(url,width,height) { open_window_byname("black",url,width,height); } function open_window2(url,width,height) { open_window_byname_with_menu("blacker",url,width,height); } function open_large_window(url) { screenX = 1; screenY = 1; width = screen.width-12; height = screen.height-124; window.open(url, 'large', 'titlebar=1,location=0,status=0,toolbar=1,menubar=1,resizeable=1,scrollbars=1,left=' + screenX + ',top=' + screenY + ',width=' + width + ',height=' + height); } function open_window_byname(windowName,url,width,height) { agent=navigator.appVersion; version=parseInt(agent); //figure out the top/left of the screen //taking the menu bar into consideration if (version>=4) { leftCorner=screen.width/2 - width/2; topCorner=screen.height/2 - height/2; }else{ leftCorner=20; topCorner=20; } features=",screenX="+leftCorner+",screenY="+topCorner+",left="+leftCorner+",top="+topCorner; features=features+",titlebar=1,scrollbars=1"; if (popWindow==null) { popWindow=open(url,windowName, "width="+width+",height="+height+ features); // for IE3, focus, closed, and opener doesn't work, so we have to tell // the window opened who's the opener if (version<3) setTimeout("popWindow.mama=window",250); }else{ if (version<3) { popWindow.close(); popWindow=null; setTimeout("open_window('"+url+"',"+width+","+height+")", 250); setTimeout("popWindow.mama=window",500); }else if (!popWindow.closed){ popWindow.close(); popWindow=null; setTimeout("open_window('"+url+"',"+width+","+height+")", 250); }else{ popWindow=null; popWindow=open(url,windowName, "width="+width+",height="+height+features); } } } function open_window_byname_with_menu(windowName,url,width,height) { agent=navigator.appVersion; version=parseInt(agent); //figure out the top/left of the screen //taking the menu bar into consideration if (version>=4) { leftCorner=screen.width/2 - width/2; topCorner=screen.height/2 - height/2; }else{ leftCorner=20; topCorner=20; } features=",screenX="+leftCorner+",screenY="+topCorner+",left="+leftCorner+",top="+topCorner; features=features+",toolbar=1,scrollbars=0,resizable=1"; if (popWindow==null) { popWindow=open(url,windowName, "width="+width+",height="+height+ features); // for IE3, focus, closed, and opener doesn't work, so we have to tell // the window opened who's the opener if (version<3) setTimeout("popWindow.mama=window",250); }else{ if (version<3) { popWindow.close(); popWindow=null; setTimeout("open_window('"+url+"',"+width+","+height+")", 250); setTimeout("popWindow.mama=window",500); }else if (!popWindow.closed){ popWindow.close(); popWindow=null; setTimeout("open_window('"+url+"',"+width+","+height+")", 250); }else{ popWindow=null; popWindow=open(url,windowName, "width="+width+",height="+height+features); } } } function open_new_window(url) { agent=navigator.appVersion; version=parseInt(agent); features="titlebar=1,scrollbars=1,location=1,toolbar=1,resizable=1"; if (popWindow==null) { popWindow=open(url,"_blank", features); // for IE3, focus, closed, and opener doesn't work, so we have to tell // the window opened who's the opener if (version<3) setTimeout("popWindow.mama=window",250); }else{ if (version<3) { popWindow.close(); popWindow=null; setTimeout("open_window('"+url+"')", 250); setTimeout("popWindow.mama=window",500); }else if (!popWindow.closed){ popWindow.close(); popWindow=null; setTimeout("open_window('"+url+"')", 250); }else{ popWindow=null; popWindow=open(url,"_blank", features); } } }