WebAIR

Do you specify changes of language within the webpage (e.g. a French quotation within English text)? (TXT23)

Why is this important?

As well as specifying the language of a webpage on the whole, it is also important to specify any changes in the language of a webpage.

How to fix the problem

Specify the language of a webpage by providing the "lang" and/or "xml:lang" attribute on the element in which the change of language occurs (e.g. a <blockquote> element).

Example

//Specifying the language of a quotation is French, using the "lang" and "xml:lang" attribute of the <blockquote> element

<blockquote xml:lang="fr">
<p>
Il s'agit de la traduction d'un bloc de texte en français.
</p>
</blockquote>

Further Information

  1. https://www.w3.org/International/questions/qa-html-language-declarations