[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Re: XSLT (2) namespace safe i18n patterns

Subject: Re: XSLT (2) namespace safe i18n patterns
From: Andrew Welch <andrew.j.welch@xxxxxxxxx>
Date: Tue, 24 Nov 2009 10:43:17 +0000
Re:  XSLT (2) namespace safe i18n patterns
2009/11/23 Syd Bauman <Syd_Bauman@xxxxxxxxx>:
> My gut instinct is that it is a less than optimal solution to try to
> use namespaces to differentiate natural languages. That's what
> xml:lang= is for, after all.
>  <z>
>    <canonical>MD</canonical>
>    <name xml:lang="en">medical doctor</name>
>    <name xml:lang="fr">midecin</name>
>    <name xml:lang="zh-TW">...</name>
>  </z>

I think xml:lang had become another hangover from the days of XML
rendered using CSS, when XLink and XPointer seemed like good ideas

A few years down the line, the usual advice is to avoid xml:lang and
create your own markup (simply @lang for example), or to avoid mixing
languages in the same document all together, splitting them out into
separate documents.

For example, in the above example, you could just have:


where "medical_doctor" is the key for a lookup into your translations,
which are held in separate files.

Andrew Welch
Kernow: http://kernowforsaxon.sf.net/

Current Thread


Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
First Name
Last Name
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.