W3C home > Mailing lists > Public > public-html@w3.org > September 2007

New elements vs. Trident

From: Maciej Stachowiak <mjs@apple.com>
Date: Sat, 15 Sep 2007 23:49:53 -0700
Message-Id: <7EDF32DA-5FA2-4F8D-AFEF-611A1FEFC448@apple.com>
To: "public-html@w3.org WG" <public-html@w3.org>

While working on examples for the "Degrade Gracefullly" principle, I  
realized that IE's handling of unknown elements makes it somewhat  
challenging to do graceful degradation for any new elements.

Something like this:

<newelement><em>some text</em></newelement>

Creates a DOM like this:

         #text: some text

In other words, instead of wrapping the unknown element around its  
contents, IE adds an empty elment named "NEWELEMENT" at the start tag,  
and another empty element named "/NEWELEMENT" at the end tag. (Note  
that this behavior is also in violation of HTML 4.01


This creates obvious problems with graceful degradation for new  
elements - it's not possible to style them, add event listeners, or in  
general work with them as expected in the DOM.

Fortunately, it's easier to do a script-based fixup since there is a  
marker for where the end of the element should have been in the DOM;  
apparently this was done before for the <abbr> element, which IE6  
handled as an unknown element: <http://dean.edwards.name/IE7/>.

However, it would be nice to avoid the need for such script hacks. Can  
anyone from Microsoft comment on the possibility of fixing the  
handling of unknown elements in IE, even well in advance of broader  
implementation of HTML5?

Received on Sunday, 16 September 2007 06:50:04 UTC

This archive was generated by hypermail 2.3.1 : Thursday, 29 October 2015 10:15:26 UTC