[whatwg] xml:lang and xmlns in HTML
rubys at intertwingly.net
Fri Dec 1 10:21:03 PST 2006
Ian Hickson wrote:
> On Fri, 1 Dec 2006, Michel Fortin wrote:
>> I wonder if xml:lang and xmlns couldn't be made legal in HTML. xml:lang
>> would simply become conformant in HTML as a synonym for the lang
>> attribute, it's already in the spec that it should get the correct
>> treatment anyway.
> Except that wouldn't be backwards compatible since xml:lang="" isn't
> treated as a language attribute in legacy UAs.
I thought that the HTML definition of backwards compatibility was "If a
user agent encounters an attribute it does not recognize, it should
ignore the entire attribute specification (i.e., the attribute and its
>> This would make it possible to have documents conformant with both
>> syntaxes at the same time.
> I thought XHTML-sent-as-text/html had explained in painful detail why
> that's not a desirable end goal. Why would we want this?
Perhaps the problem is that your reformulation of Michel's assertion
doesn't capture the essence of the perceived requirement. And given the
frequency with which this question comes up, there probably is a kernel
of validity hiding in there somewhere.
>> This could also help reinforce the idea that it's the media type that
>> differentiate HTML from XHTML. It'd make many valid XHTML1 documents out
>> there conformant with HTML5 with a mere modification to the doctype.
> Not if they use things like <![CDATA[...]]> or the empty element syntax on
> non-void elements, or any number of other XMLisms.
Until yesterday, empty element syntax on void elements was also an
XMLism. Perhaps the question as to whether <![CDATA[..]]> should be
allowed should be explored with the same pragmatism as the empty/void
question was pursued.
>> What do you think?
> I don't think it's a goal for the two serialisations to have a common
Whether it is a goal or not, it is a reality that the two serializations
are enough similar to confuse many. You can try to ignore it or wish it
wasn't so, but it is a reality that should be dealt with.
I've posted further thoughts here:
Note: if you go to that page, I'd highly recommend using a browser that
understands the application/xhtml+xml MIME type.
- Sam Ruby
More information about the whatwg