Lesson
#5 Review Questions
1. According to
the Netscape Document Object Model, which object is at the top of the hierarchy
in a browser window?
2. Objects such
as forms and images are contained in what parent or container object?
3. The Hot Rod Racing
Club has asked you to create their user login web screen, so you have a text
box named userName that sits on a form named userLogin. We want to pre-initialize
the value in that box to "new member type Guest". You would use:
4. One of the events
for a window object is called Focus, meaning that the window is selected by
the user. The event handler for that event would be called:
5. Often, web sites have a sponsor's
ad pop open just as you try to exit their site by closing the browser window.
What is the event handler that causes the ad to pop up?
6. To create a visual
effect called a rollover, we set an image to one source file as the document
loads. Then when the user rolls their mouse over that image, the onMouseOver
event calls up a difference source image from a different file. To make the
original image re-appear when the user moves the mouse off of the image, we
would use which event handler?
7. Which of the following is the correct explanation
of why there are single quotes around the message?
onError
= "alert('Our Web Site is having a bad day. Please call 1-800-999-9999
for service.');"
8. You have created
a web page for your school's fund raising project, and when a user clicks
a certain checkbox, you wish to have a "Thank You" message pop up.
Finish the code for the event handler: <INPUT TYPE="checkbox"
NAME="chkSendMoney" onClick=
9. If your web page
loads an image from another url there are lots of potential errors (such as
maybe the other server is off line!, or a connection is down, etc ) so you
may want to display a polite "Oops" message if the image fails to
load. Which is the correct way to code the event handler?
10. For a special holiday promtion,
you wish to display a special message when a user first opens the Rock Candy
Village web site. What event handler will do the job?