HTML and CSS Reference
In-Depth Information
Line 101 declares the popUpNotice() function. The statement in line 102 opens
the chapter10-1notice.html Web page as a pop-up window that is 520 pixels wide and
330 pixels high. Line 103 closes the function.
To Enter the popUpNotice() Function to Open a Pop-Up Window
The following step enters the popUpNotice() user-defined function that contains the open() method to open
the chapter10-1notice.html file in a pop-up window.
.html window.
Activate the
line directly above
the //--> tag, and press
the e n t e r key once.
Click line 100, the
JavaScript statement to
open pop-up window
On line 101
, enter
the JavaScript code
from Table 10-29 on
the previous page,
indenting as shown,
and press the e n t e r
key after line 103
(Figure 10-34).
no spaces in Window
dimension attributes
Figure 10-34
To Add the Event Handler to Call the popUpNotice() Function
Now you need to add the onLoad event handler to open the pop-up window when the Web page loads. Each
function name is enclosed in one set of quotation marks and separated by a semicolon. The following steps add the
second function call to the onLoad() event handler.
point in front of
the “> at the end
of line 162 (the
line that begins
<body onLoad= )
(Figure 10-35).
Position the insertion
do not press
e n t e r after typing
click before quotation
marks and do not press
s p a c e b a r before typing
Figure 10-35
Search WWH ::

Custom Search