Language: Test of natural language markup through CSS

This page tests your XML user agent (such as internet browser) for language markup. The page is written in XHTML 1.1 and applies CSS 2.1.

References

Tests of language dependent markup

Desired results

  1. English text with this markup.
  2. German text with this markup.
  3. Danish text with this markup.

Test set: CSS selector: :lang(foo) {}

HTML 4.01 attribute: lang="foo"

  1. This text is in English.
  2. Dieser Text ist auf Deutsch.
  3. Denne tekst står på dansk .

XHTML 1.0 Strict attributes: xml:lang="foo" lang="foo"

  1. This text is in English.
  2. Dieser Text ist auf Deutsch.
  3. Denne tekst står på dansk.

XHTML 1.1 attribute: xml:lang="foo"

  1. This text is in English.
  2. Dieser Text ist auf Deutsch.
  3. Denne tekst står på dansk.

Test set: CSS selector: *[lang="foo"] {}

HTML 4.01 attribute: lang="foo"

  1. This text is in English.
  2. Dieser Text ist auf Deutsch.
  3. Denne tekst står på dansk .

XHTML 1.0 Strict attributes: xml:lang="foo" lang="foo"

  1. This text is in English.
  2. Dieser Text ist auf Deutsch.
  3. Denne tekst står på dansk.

XHTML 1.1 attribute: xml:lang="foo"

  1. This text is in English.
  2. Dieser Text ist auf Deutsch.
  3. Denne tekst står på dansk.