- From: Robert Burns <rob@robburns.com>
- Date: Sun, 16 Sep 2007 01:46:30 -0500
- To: Maciej Stachowiak <mjs@apple.com>
- Cc: "public-html@w3.org WG" <public-html@w3.org>
- Message-Id: <9D9126AC-ACA8-4CE2-85E4-7B2911414233@robburns.com>
Hi Maciej, On Sep 16, 2007, at 1:01 AM, Maciej Stachowiak wrote: > While working on examples for the "Degrade Gracefullly" principle, > I realized that the Gecko handling of unknown elements makes it > pretty hard to do graceful degradation for new block-level > elements. I thought initially that just adding a "display: block" > style rule would cut it, and that does work as expected in Safari > and Opera. > > However, in Firefox, the open tags of known block-level elements > force unknown elements to be closed. This results in elements like > <article> or <section> being siblings of their intended block > children, rather than their parents, which makes it difficult to > apply styling or event listeners. You might want to take a look at the wiki page "Thought Experiment In Graceful Degradation". We are actually accumulating some valuable pages on the wiki and this one definitely helps understanding these graceful degradation issues. It is collecting information on graceful degradation. The issue with Firefox is that it actually assumes unknown elements that get block elements added to them. For example, an unknown element could have the same content model as a 'p' element and still work in Firefox. However, it cannot allow any structured inline or block level elements or Gecko assumes that an authoring error has occurred that accidentally omits the closing tag (or that the element is just like a 'p' element and permits omitted closing tags). > Here's a simple example: > > [...] > > This has apparently been filed already as <https:// > bugzilla.mozilla.org/show_bug.cgi?id=311366>. Can any Mozilla > representatives in this group comment on whether it's possible to > fix this for Firefox 3 or otherwise relatively soon? That would be great to get that fixed sooner than later. > > Note: handling of new block elements will be problematic in IE as > well for other reasons. I'm writing a separate email about that. > Yes, IE treats unknown elements as void elements [1]. Its also worth noting that all of the majjor browsers have similar shortcomings when it comes to unknown head elements. It would be best to get all unknown elements working better in both head and body (this would facilitate spec updates better in my view). Take care, Rob [1]: <http://esw.w3.org/topic/HTML/ ThoughtExperimentInGracefulDegradation>
Received on Sunday, 16 September 2007 06:47:09 UTC