W3C

 

On this page

More tests

HTML & CSS tests page

Test home page

HTML+CSS Internationalization Tests
Language declarations

This page groups together pages being developed by the Internationalization Core Working Group to assess internationalization support of user agents. These tests are still under development and should not be taken as final.

Note that Internationalization WG tests do not only test conformance with W3C standards. In some cases the tests also allow for exploration of the behavior of user agents in ways not described by the standards.

Basic declarations [results]

  1. lang attribute in html tag
    The browser will recognize a language declared in a lang attribute on the html tag.
    HTML4 HTML5 XHTML1.0html XHTML1.0xml XHTML5 XHTML1.1
  2. xml:lang attribute in html tag
    The browser will recognize a language declared in a xml:lang attribute on the html tag.
    HTML4 HTML5 XHTML1.0html XHTML1.0xml XHTML5 XHTML1.1
  3. HTTP header
    The browser will recognize a language declared in the HTTP header.
    HTML4 HTML5 XHTML1.0html XHTML1.0xml XHTML5 XHTML1.1
  4. Content-Language meta element
    The browser will recognize a language declared in a meta element in the head using http-equiv='Content-Language' content='..' (with a single language tag value).
    HTML4 HTML5 XHTML1.0html XHTML1.0xml XHTML5 XHTML1.1

Conflicting declarations [results]

  1. HTTP header and html lang
    If there is a conflict between the language declarations in the HTTP header and the html element using lang, the UA will recognize the language declared in the html element.
    HTML4 HTML5 XHTML1.0html XHTML1.0xml XHTML5 XHTML1.1
  2. HTTP header and html xml:lang
    If there is a conflict between the language declarations in the HTTP header and the html element using xml:lang, the UA will recognize the language declared in the html element.
    HTML4 HTML5 XHTML1.0html XHTML1.0xml XHTML5 XHTML1.1
  3. HTTP header and meta element
    [Exploratory test] If there is a conflict between the language declarations in the HTTP header and the Content-Language meta element, the UA will recognize the language declared in the meta element.
    HTML4 HTML5 XHTML1.0html XHTML1.0xml XHTML5 XHTML1.1
  4. html lang and meta elements
    [Exploratory test] If there is a conflict between the language declared using lang in the html element and that in the meta element, the UA will recognize the language declared in the html element.
    HTML4 HTML5 XHTML1.0html XHTML1.0xml XHTML5 XHTML1.1
  5. html xml:lang and meta elements
    [Exploratory test] If there is a conflict between the language declared using xml:lang in the html element and that in the meta element, the UA will recognize the language declared in the html element.
    HTML4 HTML5 XHTML1.0html XHTML1.0xml XHTML5 XHTML1.1

Empty language value [results]

  1. lang="..." vs lang=""
    If an element contains a language attribute with an empty value, the value of a language attribute higher up the document tree will no longer be applied to the content of that element.
    HTML4 HTML5 XHTML1.0html XHTML1.0xml XHTML5 XHTML1.1
  2. lang="" vs HTTP
    If the HTTP header contains a language declaration but the html element uses an empty lang attribute, the UA will not recognize the language declared in the HTTP header.
    HTML4 HTML5 XHTML1.0html XHTML1.0xml XHTML5 XHTML1.1
  3. lang="" vs meta Content-Language
    If the meta Content-Language element contains a language declaration but the html element uses an empty lang attribute, the UA will not recognize the language declared in the meta Content-Language element.
    HTML4 HTML5 XHTML1.0html XHTML1.0xml XHTML5 XHTML1.1
  4. xml:lang="" vs HTTP
    If the HTTP header contains a language declaration but the html element uses an empty xml:lang attribute, the UA will not recognize the language declared in the HTTP header.
    HTML4 HTML5 XHTML1.0html XHTML1.0xml XHTML5 XHTML1.1
  5. xml:lang="" vs meta Content-Language
    If the meta Content-Language element contains a language declaration but the html element uses an empty xml:lang attribute, the UA will not recognize the language declared in the meta Content-Language element.
    HTML4 HTML5 XHTML1.0html XHTML1.0xml XHTML5 XHTML1.1

Multiple values [results]

  1. First of multiple languages in HTTP header
    [Exploratory test] The UA will recognize the first language declared where more than one language is declared in the HTTP Content Language header.
    HTML4 HTML5 XHTML1.0html XHTML1.0xml XHTML5 XHTML1.1
  2. Second of multiple languages in HTTP header
    [Exploratory test] The UA will recognize the second language declared where more than one language is declared in the HTTP Content Language header.
    HTML4 HTML5 XHTML1.0html XHTML1.0xml XHTML5 XHTML1.1
  3. First of multiple languages in Content-Language meta element
    [Exploratory test] The UA will recognize the first language declared where more than one language is declared in the Content-Language meta element.
    HTML4 HTML5 XHTML1.0html XHTML1.0xml XHTML5 XHTML1.1
  4. Second of multiple languages in Content-Language meta element
    [Exploratory test] The UA will recognize the second language declared where more than one language is declared in the Content-Language meta element.
    HTML4 HTML5 XHTML1.0html XHTML1.0xml XHTML5 XHTML1.1

Copyright © 2013 W3C ® (MIT, ERCIM, Keio, Beihang) Usage policies apply.
Content last changed 2010-04-12 12:02 GMT.