Sent by Matthias Gutfeldt on 13 January 2003 07:07
--- Luc [EMAIL-REMOVED]> wrote:
> Since IE6 i'm a bit confused as to what Doctype to use.
No, you are not confused - the browsers are confused :-).
> In order to get a page validated, using HTML & Css1
> (or Css2) what would be the best Doctype to use:
> 4.01 Transitional with our without URI? I'm
> looking for a crass browser doctype (if that
> should exist at all).
> I always used to use 4.01 transitional without URI
> (but that's before i started using Css). My goal
> was always to not get the quirks mode but
> now i'm not sure if that has an influence when using Css.
Yes, there are quite some CSS differences between the two modes. The
differences in IE6, and which Doctype triggers which mode, are
explained here:
<http://msdn.microsoft.com/workshop/author/css/overview/cssenhancements.asp>
You should keep in mind that IE6 has an ugly bug: If there's anything
before the <!Doctype declaration, it will switch into quirks mode.
This means for XHTML documents that an XML declaration, e.g. <?xml
version="1.0" encoding="UTF-8"?>, will cause the browser to use quirk
mode. If you want to avoid this, you can, in some cases, remove the
XML declaration and declare the charset in some other suitable place.
See <http://www.w3.org/TR/xhtml1/#C_9> for details.
In Mozilla there are also differences, but different from the ones in
IE6 (yeah, it sucks). They are explained here:
<http://www.mozilla.org/docs/web-developer/quirks/quirklist.html>.
And which Doctype triggers what mode in Mozilla (Standard, Almost
Standard, or Quirk) is listed here:
<http://www.mozilla.org/docs/web-developer/quirks/doctypes.html>
My own table at
<http://www.gutfeldt.ch/matthias/articles/doctypeswitch/table.html>
hasn't been updated with this new Almost Standard Mode; I fully
expect Mozilla to invent new modes and different switching algorithms
in the near future. I'll update the table when the dust settles... in
the meantime, my article over at
<http://www.gutfeldt.ch/matthias/articles/doctypeswitch.html>
explains the general concept of Doctype switching.
Matthias
__________________________________________________
Do you Yahoo!?
Yahoo! Mail Plus - Powerful. Affordable. Sign up now.
http://mailplus.yahoo.com