Re: Updated DOCTYPE versioning change proposal (ISSUE-4)

Philip Taylor, Wed, 17 Feb 2010 14:56:58 +0000:
> Leif Halvard Silli wrote:

>> My belief is shared: 

> Maciej said "If a doctype is present, then it the document is in 
> strict mode unless it is one of the doctypes that specifically 
> triggers quirks mode". This one is in the list ("The public 
> identifier starts with: "-//W3C//DTD HTML 3.2 Final//""), so it 
> specifically triggers quirks mode.

I of course see that it is in line with what Maciej said that that 
specific doctype triggers quirksmode, since it is on that list.

But my implied question was: Why has it been placed on that list? Henri 
gave me the impression that the above doctype variant has not triggered 
quirks mode until it was specified to do so, in HTML5.
> The exception Maciej didn't mention is that if the doctype is 
> syntactically invalid in certain ways, then it will trigger quirks 
> mode without looking in the list. Unexpected characters (like "[") 
> *before* the system identifier trigger it; unexpected characters 
> *after* the system identifier don't, which means pages like 
> will still be 
> non-quirks. I see the latter case on around a dozen pages (out of 
> half a million), and see the former case only on 
> which actually looks 
> *better* in quirks mode.

OK, I can confirm that in Opera 10.5beta, then - if I add the 
URL/system identifier, then the page is in QuirksMode:


Btw, until now, I had not tested Minefield myself, I only trusted 
Lachlan. But now that I have tested it, I must say that he was wrong: 
That page does not trigger quirksmode.

So, this is an attempt to create order out of chaos. Is that why the 
HTML3.2 doctype causes quirksmode too? Because there is no system 
identifier? Order instead of reality?

>> What is the purpose of starting to treat that DOCTYPE as a quirks 
>> mode trigger?
> Browsers treat many doctypes differently, so HTML5 will inevitably 
> start treating some of them differently to some existing browsers.

In my test case, HTML5 seems to treat things differently from every 
> IE uses rules similar to, so 
> anything containing the string " HTML 3" (and not containing some 
> other magic strings) will be quirks mode. HTML5 is much closer to 
> what other browsers do, but modified based on data (large-scale 
> surveys, bug reports, etc) to attempt to maximise the number of 
> legacy pages that render as the author expected. The way to change 
> the list is to provide data showing that compatibility would be 
> improved by the change.

So what do you think about the documenation I have provided:

[1] http://www.må

[2] http://www.må

[3] http://www.må

[4] http://www.må

None of these pages triggers quirks mode in IE - although, that is 
perhaps not 100% true: If you go to page [3] or [4] and click on the 
link to page [1] or [2], then IE seems to land in a "inbetween mode". 
If you thereafter reload the page ([1] or [2]), then it lands in 
perfect strict mode - and displays all margins. This is an issue 
related to parsing of the "]>" - and IE reacts positively to the steps 
I took to hide the "]>" in test [3] and [4]. Pasting the URL and 
loading the page that way does not have this effect. But at any rate: 
This has nothing to do with the system identifier.

Only Safari 4 of released browsers lands in QuirksMode on all those 
pages. Then Opera 10.5beta also does the same. But Minefiled (for Mac 
at least) does not land in Quirksmode on any of those pages.

So I think there must be some update to what triggers Quirks.
leif halvard silli

Received on Wednesday, 17 February 2010 15:58:08 UTC