W3C home > Mailing lists > Public > www-dom@w3.org > July to September 2011

Re: [DOMCore] setAttribute() and xmlns prefix match

From: Anne van Kesteren <annevk@opera.com>
Date: Wed, 31 Aug 2011 11:14:12 +0200
To: www-dom@w3.org, "Boris Zbarsky" <bzbarsky@mit.edu>
Message-ID: <op.v02mlyrj64w2qv@annevk-macbookpro.local>
On Fri, 26 Aug 2011 17:25:40 +0200, Boris Zbarsky <bzbarsky@mit.edu> wrote:
> I don't think we want that.  Why would be want it?

The current text does indeed seem wrong. I guess the question is whether  
we want to allow xmlns attributes to be manipulated and how this should  
affect the namespace and namespace prefix lookup algorithms.

<html xmlns="http://www.w3.org/1999/xhtml"><script>
   document.documentElement.setAttribute("xmlns", "test");
   document.documentElement.innerHTML = "&lt;test>&lt;/test>"

In WebKit and Gecko the <test> element will come before the <b> element in  
the final tree and will be in the "test" namespace. <html> and <b> will be  
in the HTML namespace.

Anne van Kesteren
Received on Wednesday, 31 August 2011 09:14:44 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 20 October 2015 10:46:18 UTC