W3C home > Mailing lists > Public > www-html-editor@w3.org > January to March 2003

hreflang not in xhtml2 anymore - abuse of xml:lang

From: Dominique HazaŽl-Massieux <dom@w3.org>
Date: 04 Mar 2003 19:01:58 -0500
To: www-html-editor@w3.org
Cc: karl@w3.org
Message-Id: <1046822519.9828.66.camel@cirrustier>

As I was discussing about how the type attribute in links now accepts a
list of types instead of just one and how good it was ;), I discovered
that hreflang disappeared from the possible attributes in a link (at
least, didn't I find it in

[ I haven't found any mail about this topic in the archives, I hope I'm
not repeating a known issue ]

What is the rationale to suppress hreflang? From what I've seen, this is
a useful attribute and more and more personal sites use it as a way to
indicate the language of the pages they link to. Besides, I found it
useful in combination with rel='alternate' to indicate an existing
translation of the current page.

This latest feature seems to have been replaced by the use of xml:lang
in combination with the same 'rel' attribute value; that seems to be an
abuse of xml:lang, which is supposed to apply on "the language used in
the contents and attribute values of any element" according to the XML
lang; in the case of:
<link lang="fr" title="La documentation en Fran&ccedil;ais"
(example extracted from the current XHTML 2 draft, where an erroneous
"lang" attribute has been somehow kept), the xml:lang rightly applies to
"title", but certainly not to the document you get when dereferencing
the URI that happens to be in the href attribute.

(note that you would have to use the following code to link the
translation in the body of the text:
<a href="foo.html.fr" xml:lang="fr">the French Translation of this
document</a> which is obviously wrong).

I would hence suggest re-adding the hreflang attribute or at least
document why it has been removed.

Dominique HazaŽl-Massieux - http://www.w3.org/People/Dom/

Received on Tuesday, 4 March 2003 19:04:09 UTC

This archive was generated by hypermail 2.3.1 : Wednesday, 7 January 2015 15:08:48 UTC