JavaScript allows creating and opening windows representing HTML text, form objects and frames. The window object is the top-level object of the JavaScript client hierarchy. The form elements and all JavaScript code are present in the document, and the document is loaded into the window. In order to understand how the windows work, you can control the operation of these windows.
Open and close windows
When the user starts Navigator, a window will be automatically created. Users can also use the New Web Browser on the Navigator's File menu to open a window. They can use the Close or Exit of the Navigator's File menu to close a window. They can also use the program method to open or close a window.
Open the window
Use method open to create a window. The following statement creates a window named msgWindow and displays the contents of the file in the window.
msgWindow=("")
The following statement can create a window called homeWindow to display Netscape's home page.
homeWindow=("")
A window can have two names. The following statement creates a window with two names. The first name is msgWindow to refer to the properties, methods and inclusion relationships of the window. The second name displayWindow is used to refer to the window as a form submission or hypertext chain object.
When creating a window, it is not required to give the window name. However, if you intend to reference this window from another window, the window must have a name. For information about using the window name, see window and frames for information.
When opening a window, you can specify window properties, such as the height, width of the window, whether it contains a toolbar, location field, scrollbar, etc. The following statement creates a window without a toolbar but with scrollbar.
msgWindow=
("","displayWindow","toolbar=no,scrollbars=yes")
For details on the properties of the window, please refer to the OPEN method.
Close the window
You can use method close in a program to close a window. It is not allowed to close only one frame without closing the entire parent window.
All the following statements can close the current window:
()
()
//This statement cannot be used in event handler
close()
The following statement closes a window called msgWindow:
()
--------------------------------------------------------------------------------
Using frame
A frame is a special window that can display multiple independently scrolling frames in one window. Each frame has its own different URL. Each frame can point to different URLs or be used as other URL targets, but must be in the same window. A series of frames form a page (page).
The following picture shows a window with three frames
This frame is This frame is
named listFrame named contentFrame
| |
-----------------v-----------------------------------v------------
| Music Club | Toshiko Akiyoshi |
| Artists | Interlude |
| Jazz | The Beatles |
| - T. Akiyoshi | Please Please Me |
| _ J. Coltrame | |
| - M. Davis | Betty carter |
| - D. Gordon | Ray Charles and Betty Carter |
| Soul | Jimmy Cliff |
| - B. Carter | The Harder They Come |
| _ R. Charles | |
| ... | ... |
------------------------------------------------------------------
| Alphabetical By category Musician Descriptions |
-----------------^------------------------------------------------
|
This frame is named
navigateFrame
Create a frame
You can create a frame using the <frameSET> tag in an HTML document. The only function of the <frameSET> tag in an HTML document is to define the layout of each frame that makes up the page.
Example 1 The following term name defines a set of frames shown in the figure above
<FRAMESSET ROWS ="90%,10%">
<FRAMESET COLS="30%,70%">
<FRAME SRC= NAME="listFrame">
ALT="BACKWARD" HEIGHT=32 WIDTH=32> <FRAME SRC= NAME="contentFrame>
ALT="BACKWARD" HEIGHT=32 WIDTH=32> </FRAMESET>
<FRAME SRC = NAME="navigateFrame">
</FRAMESET>
The following figure shows the hierarchy of these frames. Although two frames are defined in another frameset, these three frames have the same father. This is because the frame's father is its parent window, and the window is determined by the frame rather than the frameset.
top
+--listFrame ()
+--contentFrame()
+--navigateFrame()
You can also refer to the above frames (see frame object for information about array frames):
listframe is represented by [0]
contentframe is represented by [1]
navigateframe is represented by [2]
Example 2: Another method can be used to create the above window: The two first frames and navigateFrame each have different parents, and the frameset at the top is defined as follows:
<FRAMESSET ROWS ="90%,10%">
<FRAME SRC= NAME="upperFrame">
ALT="BACKWARD" HEIGHT=32 WIDTH=32> <FRAME SRC= NAME="navigateFrame>
ALT="BACKWARD" HEIGHT=32 WIDTH=32> </FRAMESET>
The file contains the skeleton of the above frame and defines the following frameset.
<FRAMESSET COLS ="30%,70%">
<FRAME SRC= NAME="listFrame">
ALT="BACKWARD" HEIGHT=32 WIDTH=32> <FRAME SRC= NAME="contentFrame>
ALT="BACKWARD" HEIGHT=32 WIDTH=32> </FRAMESET>
The following figure illustrates the hierarchical relationship between these frames: upperFrame and navigateFrame share a parent: the top window. The listFrame and contentFrame share a parent: upperFrame.
top
| +--listFrame
| | ()
+---upperFrame-----------|
| () |
| +--contentFrame
| ()
+--navigateFrame
()
These frames can be referenced in the following way (see frame object for information about frame arrays).
upperFrame is represented by [0]
navigateFrame is represented by [1]
listFrame is represented by [0] or [0].frames[0]
contentFrame is represented by [1] or [0].frames[1]
Update frames(updating frames)
As long as you explain the frame hierarchy, you can use the location attribute to set the URL to update the frame's content.
For example, when using the frameset in Example 2 of the previous section, if you want the user to be able to close the frame (named listframe) of the painter list containing alphabetical or classification order, and only want to see the title of the work sorted by the composer (in the contentFrame), you can add the following button to the navigateFrame.
<INPUT TYPE="button" VALUE="Titles Only"
onClick="[0].location=''">
When the user presses this button, the file is loaded into a frame named upperFrame, while the listFrame and contentFrame are closed and no longer exist.
Refer to frames and browse between frames (navigate)
Because frame is a kind of window, you can refer to frames and browse between frames in a similar way as using windows.
Example of frame
In the previous section, if frameset is designed as a available title for a music club, these frames and their HTML files include the following:
Located in the listFrame, there is a list of composers sorted by category.
Located in the contentFrame, the names of each composer and the title of the composer's work are placed in the alphabetical sequence.
Located in the navigateFrame, there is a hypertext chain, which allows the user to choose how to display the composer in the listFrame: in alphabetical or categorical order. This file also defines a hypertext chain, which allows the user to display the introduction of each composer.
Attached file is placed with composers sorted by letters. When the user wants to display the alphabetical list, press this chain and the file will be displayed in the listFrame.
Files (sorted by classification) contain codes similar to the following:
<B>Music Club Artists</B>
<P><B>Jazz</B>
<LI><A HREF=#0001 TARGET="contentFrame">Toshiko Akiyoshi</A>
<LI><A HREF=#0006 TARGET="contentFrame">Jon Coltrane</A>
<LI><A HREF=#0007 TARGET="contentFrame">Miles Davis</A>
<LI><A HREF=#0010 TARGET="contentFrame">Dexter Gordon</A>
<P><B>Soul</B>
<LI><A HREF=#0003 TARGET="contentFrame">Betty Cater</A>
<LI><A HREF=#0004 TARGET="contentFrame">Ray Charles</A>
...
Files (alphabetical) contain codes similar to the following:
<B>Music Club Artists</B>
<LI><A HREF=#0001 TARGET="contentFrame">Toshiko Akiyoshi</A>
<LI><A HREF=#0002 TARGET="contentFrame">The Beatles</A>
<LI><A HREF=#0003 TARGET="contentFrame">Betty Carter</A>
<LI><A HREF=#0004 TARGET="contentFrame">Ray Charles</A>
......
The code contained in the file (navigate chain at the bottom of the screen) is similar to the following. Note: The goal is "_parent". When the user presses this chain, the entire window is rewritten because the uppermost window is the parent of the navigateFrame.
<A HREF= TARGET="listFrame"><B>Alphabetical</B></A>
   
<A HREF= TARGET="listFrame"><B>By category</B></A>
   
<A HREF= TARGET="_parent">
<B>Musician Descriptopns</B></A>
The code included in the file (main file, displayed in the frame on the right) is roughly as follows:
<!------------------------------------------------------------------>
<A NAME="0001"><H3>Toshiko Akiyoshi</H3></A>
<P>Interlude
<!------------------------------------------------------------------>
<A NAME="0002"><H3>The Beatles</H3></A>
<P>Please Please Me
<!------------------------------------------------------------------>
<A NAME="0003"><H3>Betty Carter</H3></A>
<P>Ray Charles and Betty Carter
...
For details on creating frame syntax, see the frame object.
--------------------------------------------------------------------------------
Quoting window and frame
Which name to refer to a window depends on whether you want to refer to the properties, methods and event handlers of the window, or you want to use window as a form submission or hypertext chain object.
Because the window object is located at the top level of the JavaScript client hierarchy, window is the basis for explaining the relationship between the objects in the window.
Reference window properties, methods, and event handlers
You can use one of the following methods to reference the properties, methods and event handlers of the current window or other windows:
Self or window: self and window have the same meaning, both refer to the current window. You can choose one to reference the current window. For example, call () or () to close the current window.
top or parent: both top and parent are used to replace the name of the window. top refers to the top Navigator window, and parent refers to the window containing frameset. For example, the statement parent.="teal" sets the background color of the frame named frame2 to teal. frame2 is a frame of the current frameset.
The name of the window variable: The name of the window variable is the variable specified when opening the window. For example, close a window named msgWindow. However, if you want to open or close a window in the event handler, you must use () or (), and cannot use open() and close(). Due to the scope of static objects in JavaScript, calling close without specifying the object name is equivalent to ().
Omit the window name. Because the current window is always assumed, when calling the window method and using its properties, the window name can be omitted. For example, close() closes the current window.
For information about window methods, see window object
Example 1 Refers to the current window. The following statement refers to the form named musicform in the current window. If the check box is checked, the statement displays a warning.
if (.)
alert('The checkbox on the misicForm is checked')
Example 2 Refers to other windows. The following statements refer to the form named musicform located in the window checkboxWin. These statements determine whether the checkbox is checked, perform the checkbox check, determine whether an option to select the object is selected, and select an option to the SELECT object.
//Judge whether the check box is checked
if (.) {
alert('The checkbox on the misicForm in checkboxWin is checked')}
//Execute the check box
.=true
//A option to determine whether the select object is selected is selected
if ([1].selected)
alert('Option 1 is selected!')
//Select an option to the SELECT object
=1
Example 3: Referring to the frame in another window. The following statement refers to the frame named frame2 in window window2. This statement changes the background color of frame2 to purple, and the name frame2 must be specified in the <FRAMESET> tag. <FRAMESET> can generate frameset.
window2.="violet"
Reference a window in form commit or hypertext chain
When using a window as an object for form commit or hypertext chain (as the TARGET attribute of <FORM> or <A> tag), the window name should be used instead of using window variables. This window will be the window in which the chain is loaded, or for form, it is the window that displays the server response.
Example 1 The second window. The following example creates a hypertext chain for the second window. In this example, there is: a button, this button window can open a window named window2; a link, load the file into the latest open window; and another button, this button closes the window.
<P>
<INPUT TYPE="button" VALUE="Open window2"
onClick="msgWindow=('','resizable=no,width=200,height=200')"
<P>
<INPUT TYPE ="button" VALUE="Close window2"
onClick="()">
Example 2: The anchor in the second window. Create a hypertext chain for the anchor in the second window. This link displays the anchor named number in the window window2.
<A HREF=#numbers TARGET="window2">Numbers</A>
Example 3 The name of the frame. The following example creates a hypertext chain for the anchor in the frame. This chain is named abs_method in the file named contFrame. This frame must be placed in the current frameset, and the frame name must be defined with the NAME attribute marked with <FRAMESET>.
<A HREF=#abs_method TARGET="contentFrame">abs</A>
Example 4 The name of a common frame. The following example creates a hypertext chain for the file. This chain displays the content of the file in the parent window of the current frameset. This chain object (link object) appears in a frame of the frameset. When the user presses this link, all frames in the frameset disappear and the content is loaded into the parent window.
<A HREF="" TARGET="_parent">
<B>Musician Descriptions</B></A>
--------------------------------------------------------------------------------
Browse between windows (Navigating ambong windows)
Many Navigator windows can be opened at the same time. Users can press the window to focus this window to browse between these windows. You can use programmatic methods to focus to objects in a window, or specify this window as the target of the super text chain. Although you can change the value of the object in the second window, it cannot activate the second window, and the current window is always active.
The active window is a window with focus. Once the window has focus, this window is placed at the front and can be changed visibly. For example, the title bar of this window can change the color. The visual effect changes according to the platform you use.
Example 1 Assign focus to an object in another window. The following statement can assign focus to the text object city in the window checkboxWin. Because city obtains focus, checkboxWin also obtains focus and becomes the active window. This example also includes the statement to create a checkboxWin.
checkboxWin=("")
...
()
Example 2: Use the hypertext chain to assign focus to another window. The following sentence specifies window2 as the target of the hypertext chain. When the user presses this chain, focus is converted to window2. If window2 does not exist, it is created.
<A HREF="" TARGET="window2"> Load a file into window2</A>
Open and close windows
When the user starts Navigator, a window will be automatically created. Users can also use the New Web Browser on the Navigator's File menu to open a window. They can use the Close or Exit of the Navigator's File menu to close a window. They can also use the program method to open or close a window.
Open the window
Use method open to create a window. The following statement creates a window named msgWindow and displays the contents of the file in the window.
msgWindow=("")
The following statement can create a window called homeWindow to display Netscape's home page.
homeWindow=("")
A window can have two names. The following statement creates a window with two names. The first name is msgWindow to refer to the properties, methods and inclusion relationships of the window. The second name displayWindow is used to refer to the window as a form submission or hypertext chain object.
When creating a window, it is not required to give the window name. However, if you intend to reference this window from another window, the window must have a name. For information about using the window name, see window and frames for information.
When opening a window, you can specify window properties, such as the height, width of the window, whether it contains a toolbar, location field, scrollbar, etc. The following statement creates a window without a toolbar but with scrollbar.
msgWindow=
("","displayWindow","toolbar=no,scrollbars=yes")
For details on the properties of the window, please refer to the OPEN method.
Close the window
You can use method close in a program to close a window. It is not allowed to close only one frame without closing the entire parent window.
All the following statements can close the current window:
()
()
//This statement cannot be used in event handler
close()
The following statement closes a window called msgWindow:
()
--------------------------------------------------------------------------------
Using frame
A frame is a special window that can display multiple independently scrolling frames in one window. Each frame has its own different URL. Each frame can point to different URLs or be used as other URL targets, but must be in the same window. A series of frames form a page (page).
The following picture shows a window with three frames
This frame is This frame is
named listFrame named contentFrame
| |
-----------------v-----------------------------------v------------
| Music Club | Toshiko Akiyoshi |
| Artists | Interlude |
| Jazz | The Beatles |
| - T. Akiyoshi | Please Please Me |
| _ J. Coltrame | |
| - M. Davis | Betty carter |
| - D. Gordon | Ray Charles and Betty Carter |
| Soul | Jimmy Cliff |
| - B. Carter | The Harder They Come |
| _ R. Charles | |
| ... | ... |
------------------------------------------------------------------
| Alphabetical By category Musician Descriptions |
-----------------^------------------------------------------------
|
This frame is named
navigateFrame
Create a frame
You can create a frame using the <frameSET> tag in an HTML document. The only function of the <frameSET> tag in an HTML document is to define the layout of each frame that makes up the page.
Example 1 The following term name defines a set of frames shown in the figure above
<FRAMESSET ROWS ="90%,10%">
<FRAMESET COLS="30%,70%">
<FRAME SRC= NAME="listFrame">
ALT="BACKWARD" HEIGHT=32 WIDTH=32> <FRAME SRC= NAME="contentFrame>
ALT="BACKWARD" HEIGHT=32 WIDTH=32> </FRAMESET>
<FRAME SRC = NAME="navigateFrame">
</FRAMESET>
The following figure shows the hierarchy of these frames. Although two frames are defined in another frameset, these three frames have the same father. This is because the frame's father is its parent window, and the window is determined by the frame rather than the frameset.
top
+--listFrame ()
+--contentFrame()
+--navigateFrame()
You can also refer to the above frames (see frame object for information about array frames):
listframe is represented by [0]
contentframe is represented by [1]
navigateframe is represented by [2]
Example 2: Another method can be used to create the above window: The two first frames and navigateFrame each have different parents, and the frameset at the top is defined as follows:
<FRAMESSET ROWS ="90%,10%">
<FRAME SRC= NAME="upperFrame">
ALT="BACKWARD" HEIGHT=32 WIDTH=32> <FRAME SRC= NAME="navigateFrame>
ALT="BACKWARD" HEIGHT=32 WIDTH=32> </FRAMESET>
The file contains the skeleton of the above frame and defines the following frameset.
<FRAMESSET COLS ="30%,70%">
<FRAME SRC= NAME="listFrame">
ALT="BACKWARD" HEIGHT=32 WIDTH=32> <FRAME SRC= NAME="contentFrame>
ALT="BACKWARD" HEIGHT=32 WIDTH=32> </FRAMESET>
The following figure illustrates the hierarchical relationship between these frames: upperFrame and navigateFrame share a parent: the top window. The listFrame and contentFrame share a parent: upperFrame.
top
| +--listFrame
| | ()
+---upperFrame-----------|
| () |
| +--contentFrame
| ()
+--navigateFrame
()
These frames can be referenced in the following way (see frame object for information about frame arrays).
upperFrame is represented by [0]
navigateFrame is represented by [1]
listFrame is represented by [0] or [0].frames[0]
contentFrame is represented by [1] or [0].frames[1]
Update frames(updating frames)
As long as you explain the frame hierarchy, you can use the location attribute to set the URL to update the frame's content.
For example, when using the frameset in Example 2 of the previous section, if you want the user to be able to close the frame (named listframe) of the painter list containing alphabetical or classification order, and only want to see the title of the work sorted by the composer (in the contentFrame), you can add the following button to the navigateFrame.
<INPUT TYPE="button" VALUE="Titles Only"
onClick="[0].location=''">
When the user presses this button, the file is loaded into a frame named upperFrame, while the listFrame and contentFrame are closed and no longer exist.
Refer to frames and browse between frames (navigate)
Because frame is a kind of window, you can refer to frames and browse between frames in a similar way as using windows.
Example of frame
In the previous section, if frameset is designed as a available title for a music club, these frames and their HTML files include the following:
Located in the listFrame, there is a list of composers sorted by category.
Located in the contentFrame, the names of each composer and the title of the composer's work are placed in the alphabetical sequence.
Located in the navigateFrame, there is a hypertext chain, which allows the user to choose how to display the composer in the listFrame: in alphabetical or categorical order. This file also defines a hypertext chain, which allows the user to display the introduction of each composer.
Attached file is placed with composers sorted by letters. When the user wants to display the alphabetical list, press this chain and the file will be displayed in the listFrame.
Files (sorted by classification) contain codes similar to the following:
<B>Music Club Artists</B>
<P><B>Jazz</B>
<LI><A HREF=#0001 TARGET="contentFrame">Toshiko Akiyoshi</A>
<LI><A HREF=#0006 TARGET="contentFrame">Jon Coltrane</A>
<LI><A HREF=#0007 TARGET="contentFrame">Miles Davis</A>
<LI><A HREF=#0010 TARGET="contentFrame">Dexter Gordon</A>
<P><B>Soul</B>
<LI><A HREF=#0003 TARGET="contentFrame">Betty Cater</A>
<LI><A HREF=#0004 TARGET="contentFrame">Ray Charles</A>
...
Files (alphabetical) contain codes similar to the following:
<B>Music Club Artists</B>
<LI><A HREF=#0001 TARGET="contentFrame">Toshiko Akiyoshi</A>
<LI><A HREF=#0002 TARGET="contentFrame">The Beatles</A>
<LI><A HREF=#0003 TARGET="contentFrame">Betty Carter</A>
<LI><A HREF=#0004 TARGET="contentFrame">Ray Charles</A>
......
The code contained in the file (navigate chain at the bottom of the screen) is similar to the following. Note: The goal is "_parent". When the user presses this chain, the entire window is rewritten because the uppermost window is the parent of the navigateFrame.
<A HREF= TARGET="listFrame"><B>Alphabetical</B></A>
   
<A HREF= TARGET="listFrame"><B>By category</B></A>
   
<A HREF= TARGET="_parent">
<B>Musician Descriptopns</B></A>
The code included in the file (main file, displayed in the frame on the right) is roughly as follows:
<!------------------------------------------------------------------>
<A NAME="0001"><H3>Toshiko Akiyoshi</H3></A>
<P>Interlude
<!------------------------------------------------------------------>
<A NAME="0002"><H3>The Beatles</H3></A>
<P>Please Please Me
<!------------------------------------------------------------------>
<A NAME="0003"><H3>Betty Carter</H3></A>
<P>Ray Charles and Betty Carter
...
For details on creating frame syntax, see the frame object.
--------------------------------------------------------------------------------
Quoting window and frame
Which name to refer to a window depends on whether you want to refer to the properties, methods and event handlers of the window, or you want to use window as a form submission or hypertext chain object.
Because the window object is located at the top level of the JavaScript client hierarchy, window is the basis for explaining the relationship between the objects in the window.
Reference window properties, methods, and event handlers
You can use one of the following methods to reference the properties, methods and event handlers of the current window or other windows:
Self or window: self and window have the same meaning, both refer to the current window. You can choose one to reference the current window. For example, call () or () to close the current window.
top or parent: both top and parent are used to replace the name of the window. top refers to the top Navigator window, and parent refers to the window containing frameset. For example, the statement parent.="teal" sets the background color of the frame named frame2 to teal. frame2 is a frame of the current frameset.
The name of the window variable: The name of the window variable is the variable specified when opening the window. For example, close a window named msgWindow. However, if you want to open or close a window in the event handler, you must use () or (), and cannot use open() and close(). Due to the scope of static objects in JavaScript, calling close without specifying the object name is equivalent to ().
Omit the window name. Because the current window is always assumed, when calling the window method and using its properties, the window name can be omitted. For example, close() closes the current window.
For information about window methods, see window object
Example 1 Refers to the current window. The following statement refers to the form named musicform in the current window. If the check box is checked, the statement displays a warning.
if (.)
alert('The checkbox on the misicForm is checked')
Example 2 Refers to other windows. The following statements refer to the form named musicform located in the window checkboxWin. These statements determine whether the checkbox is checked, perform the checkbox check, determine whether an option to select the object is selected, and select an option to the SELECT object.
//Judge whether the check box is checked
if (.) {
alert('The checkbox on the misicForm in checkboxWin is checked')}
//Execute the check box
.=true
//A option to determine whether the select object is selected is selected
if ([1].selected)
alert('Option 1 is selected!')
//Select an option to the SELECT object
=1
Example 3: Referring to the frame in another window. The following statement refers to the frame named frame2 in window window2. This statement changes the background color of frame2 to purple, and the name frame2 must be specified in the <FRAMESET> tag. <FRAMESET> can generate frameset.
window2.="violet"
Reference a window in form commit or hypertext chain
When using a window as an object for form commit or hypertext chain (as the TARGET attribute of <FORM> or <A> tag), the window name should be used instead of using window variables. This window will be the window in which the chain is loaded, or for form, it is the window that displays the server response.
Example 1 The second window. The following example creates a hypertext chain for the second window. In this example, there is: a button, this button window can open a window named window2; a link, load the file into the latest open window; and another button, this button closes the window.
<P>
<INPUT TYPE="button" VALUE="Open window2"
onClick="msgWindow=('','resizable=no,width=200,height=200')"
<P>
<INPUT TYPE ="button" VALUE="Close window2"
onClick="()">
Example 2: The anchor in the second window. Create a hypertext chain for the anchor in the second window. This link displays the anchor named number in the window window2.
<A HREF=#numbers TARGET="window2">Numbers</A>
Example 3 The name of the frame. The following example creates a hypertext chain for the anchor in the frame. This chain is named abs_method in the file named contFrame. This frame must be placed in the current frameset, and the frame name must be defined with the NAME attribute marked with <FRAMESET>.
<A HREF=#abs_method TARGET="contentFrame">abs</A>
Example 4 The name of a common frame. The following example creates a hypertext chain for the file. This chain displays the content of the file in the parent window of the current frameset. This chain object (link object) appears in a frame of the frameset. When the user presses this link, all frames in the frameset disappear and the content is loaded into the parent window.
<A HREF="" TARGET="_parent">
<B>Musician Descriptions</B></A>
--------------------------------------------------------------------------------
Browse between windows (Navigating ambong windows)
Many Navigator windows can be opened at the same time. Users can press the window to focus this window to browse between these windows. You can use programmatic methods to focus to objects in a window, or specify this window as the target of the super text chain. Although you can change the value of the object in the second window, it cannot activate the second window, and the current window is always active.
The active window is a window with focus. Once the window has focus, this window is placed at the front and can be changed visibly. For example, the title bar of this window can change the color. The visual effect changes according to the platform you use.
Example 1 Assign focus to an object in another window. The following statement can assign focus to the text object city in the window checkboxWin. Because city obtains focus, checkboxWin also obtains focus and becomes the active window. This example also includes the statement to create a checkboxWin.
checkboxWin=("")
...
()
Example 2: Use the hypertext chain to assign focus to another window. The following sentence specifies window2 as the target of the hypertext chain. When the user presses this chain, focus is converted to window2. If window2 does not exist, it is created.
<A HREF="" TARGET="window2"> Load a file into window2</A>