Errata

Every book has to have one of these pages...

Final version of Project 9, Internet Explorer 6.0/Windows, and DOCTYPE.

Update: It's interesting to note that the new Safari browser from Apple also has trouble rending the pages with DOCTYPE declaration. What this means is that now more than ever, it's necessary to use valid code when creating web pages that take advantage of advanced CSS with or without added JavaScript functionality. (yes yes..something we knew all along...)

Brett Merkey pointed out in his (glowing :)) review on Amazon.com that the final versions for Projects 3 and 9 did not work in IE 6/Windows. I've been unable to verify a problem with Project 3 so far...all the pages work fine in the version of IE 6 that I have (version 6.0.2600.0000).

With Project 9's final page, the issue is a bit complicated, and in this case it's not the 'fault' per se of Netscape 4, but it's with IE 6. The culprit line is this:

window.onreload = reloadpage();

You may have been used to putting the onresize event within the <body> tag. However, for some reason this is considered to be invalid markup according to the W3C. The "correct" way of calling an window onresize event is to declare it within the <script> </script> tags. This works fine in IE 5.x/Mac and Netscape 6.x/Mozilla.

With IE 6/Windows however, it causes a looping problem which loads the page to try to load over and over. Moving the onresize function call to the <body> tag solves the script problem.

<body onload="initialize()" onresize = "reloadpage();">

However, this causes another problem with IE 6. Because this is invalid markup, when a DOCTYPE declaration if present, the page will not render properly. It doesn't matter if the DOCTYPE is Transitional or Strict. Therefore, the only workaround in this case for IE 6 is to delete the DOCTYPE declaration, in order to have the browser execute the JavaScript positioning scripts and render the page as intended. You can see this in action on the following pages: