1st Methods
The window to be opened is about.htm.
< Script Language = Javascript >
Function Openwin ()
{
Newwin = Zookeeper open('about.htm', 'login', 'location = No, Toolbar = No, status = Yes, resizable = No, scrollbars = No, menubar = No, directories = No ')
Newwin. moveTo ( - 3 , - 3 );
Newwin. resizeTo (screen. availwidth + 6 , Screen. availheight + 6 );
Window. Opener = Null ; // Opener is a container that represents the current window
Window. Close ();
}
</ Script >
2nd Methods
Write the statement for closing the old window in the onload event of the new window. This is more secure! That is, the new window is enabled, and the old window is closed.
Old window code
< Script Language = Javascript >
Function Openwin ()
{
Newwin = Zookeeper open('about.htm', 'login', 'location = No, Toolbar = No, status = Yes, resizable = No, scrollbars = No, menubar = No, directories = No ')
Newwin. moveTo ( - 3 , - 3 );
Newwin. resizeTo (screen. availwidth + 6 , Screen. availheight + 6 );
}
</ Script >
New window code
< Script Language = Javascript >
Function Closeold ()
{
Window. opener. Opener = Null ;
Window. opener. Close ();
}
Closeold ();
</ Script >
Window. Opener indicates the old window
That is, when the window is initialized, close the old window!