Re: xml:lang vs xs:language

At 2008-09-19 12:54 -0700, Kondapally Kumar wrote:
>We are having a discussion on whether to use "xml:lang" as an 
>attribute on a new element that we are defining in our xsd or 
>whether to make a new element with type "xs:language".
>
>For e.g (not syntactically correct but just to give you an idea)
>
><Newelement attribute xml:lang> </Newelement>
>
>OR
>
><Newelement >
><have another sub element with xs:language type>
></Newelement>
>
>Is there any guidance on which one to use?

The syntax and semantics of xml:lang is specified in the XML specification:

   http://www.w3.org/TR/2006/REC-xml-20060816/#sec-lang-tag

If you use xml:lang then other tools that are familiar with the 
syntax and semantics can access it, such as the lang() function in XPath.

I hope this helps.

. . . . . . . . . . . . Ken


--
Upcoming XSLT/XSL-FO hands-on courses:      Wellington, NZ 2009-01
Training tools: Comprehensive interactive XSLT/XPath 1.0/2.0 video
G. Ken Holman                 mailto:gkholman@CraneSoftwrights.com
Crane Softwrights Ltd.          http://www.CraneSoftwrights.com/x/
Male Cancer Awareness Nov'07  http://www.CraneSoftwrights.com/x/bc
Legal business disclaimers:  http://www.CraneSoftwrights.com/legal

Received on Sunday, 21 September 2008 06:26:25 UTC