W3C home > Mailing lists > Public > public-html@w3.org > February 2010

Doctypes that trigger quirks mode (was Re: Legacy Doctype and Doctype Versioning)

From: Maciej Stachowiak <mjs@apple.com>
Date: Tue, 16 Feb 2010 19:19:15 -0800
Cc: Lachlan Hunt <lachlan.hunt@lachy.id.au>, Larry Masinter <masinter@adobe.com>, "public-html@w3.org" <public-html@w3.org>
Message-id: <685C7306-C689-4A04-8987-05670EF3B053@apple.com>
To: Leif Halvard Silli <xn--mlform-iua@xn--mlform-iua.no>

On Feb 16, 2010, at 7:05 PM, Leif Halvard Silli wrote:

> Maciej Stachowiak, Wed, 20 Jan 2010 19:15:02 -0800:
>> On Jan 19, 2010, at 4:43 PM, Lachlan Hunt wrote:
>>> Larry Masinter wrote:
>
>>>> Are there documents that are conforming to HTML 4.01 but are also
>>>> "quirks mode"?
>
>>> Yes.  From the spec, these two trigger quirks mode: [...]
>>> http://www.whatwg.org/specs/web-apps/current-work/#dfnReturnLink-6
>>
>> I suspect most people know this, but just to be clear, the HTML 4.01
>> Strict DTD will *not* trigger quirks mode.
>
> No, Maciej, this is not correct. Anymore.
>
> Not in Safari 4. In the current version of Safari, this variant of the
> strict Doctype triggers QuirksMode:
>
> 	<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"
> 	[<!ATTLIST P myattr CDATA #implied  >]>

Are you reporting a bug in WebKit or a bug in the spec? WebKit bugs  
should go to <http://bugs.webkit.org/>.

>
> Whereas it does not trigger quirks mode in Opera 10.10, Firefox 3.6,
> Konqueror or IE. I also _suppose_ that in Safari 3, then it did not
> trigger QuirksMode (since it doesn't trigger quirks in Konqueror)
>
> In the just days old Opera 10.5 beta, however, there it _does_ trigger
> quirks mode. (Whereas in Opera 10.10, then it does not.)
>
> Are Webkit and Opera starting to treat anything that hasn't been
> specified to trigger Standards mode in HTML5 as QuirksMode triggers?  
> Is
> this an effect of HTML5 defining QuirksMode as the default?

HTML5 does not define quirks mode as the default. 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. The list is here:

http://dev.w3.org/html5/spec/Overview.html#quirks-mode-doctypes

I do not believe your doctype should trigger quirks mode per that list  
unless I am misreading it. That being said, if you see a flaw in that  
list, please report it.


Regards,
Maciej
Received on Wednesday, 17 February 2010 03:19:49 UTC

This archive was generated by hypermail 2.3.1 : Monday, 29 September 2014 09:39:14 UTC