[xsl] i18n and l10n question

Subject: [xsl] i18n and l10n question
From: Nicolas Van Cleemput <nicolas.vancleemput@xxxxxxxx>
Date: Mon, 06 Nov 2006 10:41:26 +0100
hi,

in our application we currently use XML-files that are structured as follows:

<factory>
  <i18n>
     <properties>
        <entry key="id1">text</entry>
        ...
     </properties>
     <node name="nl">
       <properties>
          <entry key="id1">text in other language</entry>
          ...
       </properties>
     </node>
     <node name="fr">
       <properties>
          <entry key="id1">another translation</entry>
          ...
       </properties>
     </node>
     (and so on for all the available locales)
  </i18n>
  <other_tags></other_tags>
  ...
</factory>

We are now planning to use XSL to create help pages from these XML-files. We
want this to be done with the correct rules for i18n, i.e. if the text for id1
isn't available in the demanded locale, it defaults to a lesser specific locale
untill it reaches the default locale (the one that isn't inside a
<node></node>).

Any idea how this can be done with XSL (and maybe some JAVA-programming)?

Thanks in advance,
Nico Van Cleemput
University Ghent
http://www.UGent.be

Current Thread