doctypes in IE5/Mac

Here's an interesting bit of trivia about IE5/Mac and doctypes:

http://www.alistapart.com/stories/ie5mac/ie5mac2.html

> Is there a DOCTYPE in the house?
> 
> All web pages - even this one - are supposed to begin with a
> DOCTYPE - a simple tag that tells the browser (or other device)
> what type of document it is dealing with. Common DOCTYPES include
> HTML 3.2, HTML 4.0 Transitional, HTML 4.0 Strict, and XML. 
> 
> They're essential for validating your code, but until now they
> have not been particularly useful to most browsers. Open a page
> you've designed, and change the DOCTYPE from HTML 3.2 to HTML 4.0
> strict, for example. Usually, it will make no difference in the
> rendering of the page.
> 
> In IE5/Mac, finally, it makes all the difference in the world.
> 
> In fact, you can use the DOCTYPE to determine whether you want
> 100% compliance with the standards IE5/Mac supports, or backward
> compatibility with a browser like IE5/Windows, which does not
> fully support these standards. 
> 
> Just as Text Zoom puts the user in charge of readability, DOCTYPE
> switching puts the web designer in charge of the standards
> compliance (or not) of the browser. 
> 
> For strict, standards-compliant HTML rendering, use 
> 
> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN"
> "http://www.w3.org/TR/REC-html40/strict.dtd"> 
> 
> ... and be sure to include the w3.org URL, as shown above. This
> tells the browser that you are serious about your code, and have
> validated it. For "compatible" mode, use 
> 
> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> 
> 
> ... and leave out the w3.org URL. (The presence of a W3C url
> tells IE5 to treat the document as "strict," even if you have
> marked it up otherwise.) 
> 
> IE5/Mac renders "Transitional" HTML 4 in "quirky/compatible"
> mode, which basically means it renders it the way Windows IE5
> would render it. Since IE5/Windows Edition is less
> standards-compliant than IE5/Mac, why would you ever mark up a
> document this way? 
> 
> Well, for one thing, you may want your document to look the same
> across platforms. Or you may be using the JavaScript "NAME"
> element, which would cause validation errors in a strict HTML 4.0
> document. Basically, if you are supporting older browsers,
> deploying older JavaScript, or using any workarounds, HTML 4
> Transitional is the way to go, until enough of your audience is
> using standards-compliant browsers, and you can clean up your
> code. Again, be certain to leave out the W3C url, or IE5/Mac will
> treat your code as Strict. 
> 
> We suspect that most web designers will initially specify HTML 4
> Transitional, to ensure backward compatibility and render their
> sites the same way across platforms. We further suspect that when
> Netscape releases Navigator 6, if it lives up to its billing and
> begins winning converts, web designers will finally start using
> the HTML 4.0 STRICT DOCTYPE, and validating their code. It's all
> good. ... >>


-- 
Gerald Oskoboiny       <gerald@w3.org>  +1 617 253 2920
System Administrator   http://www.w3.org/People/Gerald/
World Wide Web Consortium (W3C)      http://www.w3.org/

Received on Friday, 7 April 2000 04:36:17 UTC