Dela via


xml:lang Attribute

This content is no longer actively maintained. It is provided as is, for anyone who may still be using these technologies, with no warranties or claims of accuracy with regard to the most recent product version or service release.

Specifies the language identifier for the content of the element on which it appears. It can also optionally specify a country/region or other variation. The accepted language identifiers include:

  • en for English
  • en-GB for English (United Kingdom)
  • en-US for English (United States)
  • es-US for Spanish (United States)
  • de-DE for German (Germany)
  • fr-CA for French (Canada)

This attribute is required in voice mode. It is ignored in Dialed Number Information Service (DTMF) mode.

Syntax

<elementName
   xml:lang = (en | en-US) >
</elementName>

Example

The following example demonstrates that the word "Boston" is pronounced in English (United States).

<grammar version="1.0" xmlns="http://www.w3.org/2001/06/grammar"
 xml:lang="en-US" tag-format="semantics-ms/1.0" ...>
   <rule id="cities">
      <one-of>
         <item>Boston</item>
      </one-of>
   </rule>
</grammar>

See Also

Concepts

Grammar XML