marking language Re: Tongue twister

There isn't any contradiction. There are, as you point out, bugs in 
some tools which don't properly recognise language tagging as specified 
(but they are testing tools - no worries with users' tools...).

On the other hand it is wrong to rely on meta name="language". The 
correct method for all XML (including XHTML) is to include the xml:lang 
attribute as appropriate. The correct method for HTML (up until 
bugwards-compatible XHTML 1) is the lang attribute. You should also 
have your server sending out HTTP information identifying the 
Content-language correctly.

Cheers

Chaals

On Wednesday, Dec 3, 2003, at 04:06 Australia/Melbourne, Julian Vallis 
wrote:

>
> There are a couple of contradictions (tiny and inane ones) between 
> WCAG 1.0 and XHTML specs.
>
> XHTML 1.0 Strict and XHTML 1.1 deprecate LANG attribute (<html 
> lang="en">), in favour of <html xml:lang="en">.
>
> However WCAG 1.0 specifies:
> 11.1 Use W3C technologies when they are available and appropriate for 
> a task and use the latest versions when supported
> 11.2 Avoid deprecated features of W3C technologies.
>
> Although this is ridiculously pedantic, this basically states you 
> cannot use XHTML 1.0 Strict or XHTML 1.1 with a WAI compliant site,

No it doesn't. It says that in XHTML 1.0 Strict, or XHTML 1.1, you 
should use xml:lang not lang, since that has been deprecated. It also 
states that you should be using XHTML 1 or 1.1, as you noted.

> I'm only really raising it because the gizmos like Cynthia Says and 
> Bobby fail a site if you don't have the lang attributes. I suggest the 
> code is modified to search for just 'lang="<lang>"', whether it is 
> 'lang="en"' or 'xml:lang="en"'.

Good suggestion. There is a mailing list for the WAI Evaluation and 
Repair Tools group - http://www.w3.org/WAI/ER for more information - 
which is where you might get the attention of the developers. Most of 
them also have a feedback mechanism as part of their tool sites. Few of 
them read this list.

> ATM, in order to 'pass' tests, you have to use XHTML 1.0 Transitional 
> and put <html lang="en-gb" xml:lang="en-gb">

The tests you are ''passing' are clearly flawed...

> Personally I think this is all useless anyway, since a global 
> declaration is really the responsibility of the following META tag:

That is not correct. The specifications are pretty clear about that.

> The lang or xml:lang attribute should only be used when the language 
> changes mid-stream as such (assuming the english META had been 
> declared):
>
> <p class="bodyText">The governor of the Bank of England took a <span 
> xml:lang="fr">laissez-faire</span> attitude to raising interest 
> rates</p>

For changing language mid-stream this is indeed the way to do it.

cheers

--
Charles McCathieNevile                          Fundación Sidar
charles@sidar.org                                http://www.sidar.org

Received on Wednesday, 3 December 2003 07:30:08 UTC