• Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint
Share this Page URL
Help

Chapter 9. Handling Events > Handling Window Events

Handling Window Events

Window events occur when the user does something affecting an entire browser window. The most common window event is simply loading the window by opening a particular Web page. You can also have events that trigger event handlers when windows are closed, moved, or even sent to the background.

The onLoad Event

We have used the onLoad event frequently throughout this book. It is triggered when the user enters your page and all its elements have completed loading. A recent trend with many sites is to have an advertisement window pop up when you first get to the site. If you've ever looked at a member site on Yahoo! GeoCities, you've seen how that annoying sponsors' advertisement window appears when you load each page on the site. Because we've used this event handler so much previously (see Chapters 1 and 3 for some examples), we won't make you sit through another example of it.


PREVIEW

                                                                          

Not a subscriber?

Start A Free Trial


  
  • Creative Edge
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint