xsl-list
[Top] [All Lists]

Re: [xsl] XSLT (2) namespace safe i18n patterns

2009-11-24 06:45:56
Andrew Welch wrote:

  Hi,

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

A few years down the line, the usual advice is to avoid
xml:lang and create your own markup (simply @lang for example)

  Quite weird.  I agree @xml:lang does not give you that much,
but I cannot see what @lang could give you more.  At least
@xml:lang comes with a common definition and with fn:lang().

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:

<name>medical_doctor</name>

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

  That's a good pattern I think, but I guess there is room for
several approaches, depending on the real problems.  But even
there, in order to "lookup into your translations", you need to
tag them with their respective languages.  I cannot see why @lang
would be better than @xml:lang.

  Regards,

-- 
Florent Georges
http://www.fgeorges.org/



























--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--