[whatwg] xml:lang and xmlns in HTML

Ian Hickson ian at hixie.ch
Fri Dec 1 17:38:52 PST 2006

On Fri, 1 Dec 2006, Robert Sayre wrote:
> On 12/1/06, Ian Hickson <ian at hixie.ch> wrote:
> > On Fri, 1 Dec 2006, Robert Sayre wrote:
> > >
> > > I want to cut and paste MathML and SVG and other things into my web
> > > pages.
> > 
> > Then you'll have to use the XML variant and the XML MIME type.
> Why?

Because MathML and SVG are XML languages. I gave an apt analogy in my 
previous e-mail: if you want to use JavaScript code snippets, you have to 
use JavaScript and can't use, say, C++ or VBScript. If you want to use XML 
languages, then you have to use XML and can't use other formats like HTML 
or n3 or JSON.

> I don't care if features that rely on XML serialization break.

I *really* don't understand what you're asking for. You want to be able to 
use some features but don't care if they work or not?

> > The only ways to use namespaces outside of HTML right now with HTML5 DOMs
> > is to either use the XML serialisation, or use a lot of very verbose
> > JavaScript with DOM manipulation.
> ...
> > Namespaces aren't supported by the "tag soup" processors. If you want to
> > use namespaces, you have to use XML.
> I don't want to use namespaces. I want to use an xmlns attribute.

The only possible reasoning I could see for such a strange request would 
be if you intended to try and parse HTML documents using an XML parser. 
But then that makes no sense -- if you wanted to use an XML parser, then 
you would just use XML. Why would you not want to use XML if you wanted to 
use an XML parser?

Could you explain the use case for xmlns="" if you don't actually want 
namespaces? It may be that you are assuming a solution to a problem I 
don't understand, and that there may be some other solution to the problem 
that makes more sense.

Ian Hickson               U+1047E                )\._.,--....,'``.    fL
http://ln.hixie.ch/       U+263A                /,   _.. \   _\  ;`._ ,.
Things that are impossible just take longer.   `._.-(,_..'--(,_..'`-.;.'

More information about the whatwg mailing list