Chapter 9: Handling Events

Return to Chapter 9

 

To use this script on your own page, click in the text area below, select all, and copy to grab the script. Then, just paste into your own page — and you're done.

Handling Window Events: onresize

See it run: Handling Window Events: onresize

Script 9.3

This HTML includes the JavaScript hidden inside a multiline comment, since it's meant for use in older browsers. The script forces a reload to work around a Netscape 4 bug.

Script 9.4

You can fix Netscape 4's dynamic content redraw bug with this JavaScript.