W3C home > Mailing lists > Public > www-style@w3.org > December 2007

RE: standard out of the box

From: Alan Gresley <alan1@azzurum.com>
Date: Fri, 21 Dec 2007 17:22:44 -0700
To: Barry Rader <brader@boldinternet.com>
cc: www-style@w3.org
Message-ID: <20071221172244.34b83c2f3c9bef00757a2c62c0fb7450.1b51bf4aef.wbe@email.secureserver.net>

Barry Rader wrote:

> "Maybe sniffing out * html and *+html or similar in the CSS could also 
> result in the document displaying in legacy mode."
> 
> I personally do not believe that IE8 should not do any css sniffing.


I agree that IE8 shouldn't do any sniffing but there is not to many alternatives. If IE8 is standards out of the box, then all that can be used to trigger a legacy mode that allow for backward compatibility is what is present in the CSS or html already.


> The trigger should remain the same in all cases, "the doctype". When the 
> doctype is used quirks mode should be off period. If the website is then 
> broken it is the websites maintainer responsibility in that case. This 
> is not something new standards mode has been around for a while a 
> responsible web developer should have accounted for such. This is the 
> same problem facing HTML5 as well supporting unclosed tag elements for 
> legacy reasons.


A say this with the assumption that IE8 will have three layout engines. The new Standards mode of IE8 and the almost standards mode and quirks mode of the IE7 engine. All a doctype should do is what it currently does. If there is no doctype or a doctype is present that does trigger quirks mode then "quirks mode it will be. If the doctype triggers standards mode then the new standards mode engine in IE8 should be used. The acceptions would be:

1) For corporate infrastructure and like a setting should be present that allows tech persons to set IE8 in any mode.

2) If conditional comments are present or any * html *+html hacks are present. The IE7 engine will kick in. It's mode being depended on the doctype or absence of.

3) If conditional comments are present or any * html *+html hacks are present. Then the new Standards mode should kick in if a trigger is present in a CSS comment. This should not have any version reference.

/* [IE standard] */

This allows authors to support IE8 in standards mode along with supporting IE7 or earlier. The author doesn't have to remove any conditional comments or hack from their code as a propriety and can solely focus on IE8 in standards mode.

The problem I could see with sniffing conditional comments is similar to what happens currently with in IE7. I believe that conditional comment are responsible for the IE7 engine recognizing any html comment as part of the document tree. This is far from being standard compliant since sibling selectors may select different elements to other UAs if the html has comments. On the flip side I believe conditional comment are also responsible for IE7 falling for *+html hack and similar. The * selector in this hack is the doctype. I have come to this conclusion from these five test all linked together. When I wrote these test I was just beginning to use a xml prolog so it is dated.

http://css-class.com/test/css/selectors/ie7hacktargetingopera.htm

If IE8 sniffs the conditional comment and the result is the same as with IE7 presently then the only fullback are the CSS hacks. This could possibly come with a call to "rehack your CSS." I will pretend I didn't write that. ;-)

This allows IE8 to pass the Acidtest2 and be standard out of the box and supports what Håkon has said on this issue.


> I think the onus here is on the website creators. It should not be on 
> the browser vendors to fix the workings of peoples non-standard HTML 
> practises.


I agree, there will be broken pages but that come with progress and the trend towards interoperability.


> I think the solution here should be pretty simple. If there is a doctype 
> the website author is responsible> If there is no doctype then let the 
> current quirks mode render it accordingly. No need to give added 
> functionality to quirks mode leave it alone. Those people currently 
> developing for quirks mode will have the functionality they currently 
> know and understand. Those working in standards mode should be 
> professional about it and take responsibility for their work.


Remember there are currently doctypes that do trigger quirks mode. I now believe that allowing users to select modes is wrong.


> Those working in quirks mode wanting the added functionality of CSS 
> advancements, will need to learn proper HTML/XHTML and to develop within 
> standards.
> 
> Barry Rader
 

Totally agree

Alan

http://css-class.com/
Received on Saturday, 22 December 2007 00:22:59 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Monday, 27 April 2009 13:54:57 GMT