tomtama.blogg.se

Text services and input languages
Text services and input languages







text services and input languages

Instead, move the attribute containing text in a different language to another element, as shown in this example, where the a element inherits the default en setting of the html element.Įspañol What if there's no element to hang your attribute on? For more information see the companion article, HTTP headers, meta elements and language information. Whether or not you use the HTTP header, you should always declare the language of the text in a page using a language attribute on the html tag. You should never use a meta element with the http-equiv attribute set to Content-Language to indicate the language of a page, but in certain circumstances you may want to serve language information with the HTTP header to indicate the intended audience of your page. Use nested elements to take care of content and attribute values on the same element that are in different languages.

text services and input languages

There is no good solution for this at the moment. The same goes for multiple languages in attribute values. If you have multilingual text in the title element, you cannot mark up parts of the text for different languages because the title attribute only allows characters – no markup. In some parts of your code you may have a problem. You can find subtags using the unofficial Language Subtag Lookup tool. Use language tags from the IANA Language Subtag Registry. (For pages served as XML, including XHTML 1.x and HTML5 polyglot documents, see Choosing the right attribute.) Use the lang attribute for pages served as HTML. This allows you to style or process it differently. When the page contains content in another language, add a language attribute to an element surrounding that content. Note that you should use the html element rather than the body element, since the body element doesn't cover the text inside the document's head element. Quick answerĪlways use a language attribute on the html tag to declare the default language of the text in the page. It begins with an overall summary, then provides additional details in subsequent sections. This page describes how to mark up an HTML page so that it gives information about the language of the page. How should I set the language of the content in my HTML page?









Text services and input languages