W3C home > Mailing lists > Public > public-qt-comments@w3.org > April 2009

[Bug 6777] In HTML documents, no-namespace expression must match http://www.w3.org/1999/xhtml nodes

From: <bugzilla@wiggum.w3.org>
Date: Mon, 06 Apr 2009 18:40:15 +0000
To: public-qt-comments@w3.org
Message-Id: <E1Lqtjz-0007qR-8M@wiggum.w3.org>

--- Comment #20 from Henri Sivonen <hsivonen@iki.fi>  2009-04-06 18:40:14 ---
(In reply to comment #19)
> (In reply to comment #18)
> > (In reply to comment #16)
> > > I think the tools you have to work with have already been identified - you have
> > > control over the mapping to the data model, and you have control over the
> > > default element namespace for queries. 
> > 
> > The data model approach would mean that you could never even in the future
> > write unified XPath expressions for both text/html and application/xhtml+xml
> > DOMs.
> I don't understand this argument. You want us to treat these as though they
> have the same name. You have control over the XDM that is used for processing.
> You can give them the same name in the XDM.

The thing is that HTML nodes need to match against two kinds of expressions:
1) Expressions from the past the have no namespace.
2) Expressions from the future that have the http://www.w3.org/1999/xhtml

Basically, the issue is having the backwards-compatibility cake and eating the
HTML/XHTML DOM consistency cake, too.

> They never look to see where the data model came from - in fact, 
> there's nothing in our data model to tell us where its data 
> originally came from. That's how it should be.

There isn't an HTMLness flag in the W3C DOM, either. Ideally, that's how it
should be. Unfortunately, compatibility with existing content requires DOM
documents in browsers to know where they came from. In DOM Level 2, even
element nodes were different depending on where they come from. That's what's
implemented in Gecko today.

HTML 5 is trying to contain this problem by reducing these differences so that
element nodes no longer know where they came from but their owner document
still knows and needs to be queried in a handful of cases. This is what's
implemented in WebKit today and what's being implemented in Gecko.
Unfortunately, the only place in the entire browser platform (discovered so
far, I suppose) where this effort has a negative impact on elegance and
complexity in XPath as used in document.evaluate().

Configure bugmail: http://www.w3.org/Bugs/Public/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.
Received on Monday, 6 April 2009 18:40:25 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 16:57:27 UTC