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

Re: Globalization with XSL-XML

Subject: Re: Globalization with XSL-XML
From: "cutlass" <cutlass@xxxxxxxxxxx>
Date: Tue, 13 Nov 2001 10:26:33 -0000
xsl xml lang
the probs with multi lingual are

a) how to deal with text and local styling of text
b) how to deal with other binary assets ( i.e. pictures that are gifs )
c) should the application 'read' in the language of the client and parse in
realtime


a)

I use a global template that matches txt, and a global param that gets
passed in to the current template <xsl:param name="lang"/>

here is the global template

<xsl:param name="lang"/>

<xsl:template match="txt">
<xsl:if test="@xml:lang=$lang">
<xsl:copy-of select="node()"/>
</xsl:if>
</xsl:template>

example;

<xsl:include href="global.xsl"/> <!---- this imports your global
template --->

<xsl:template match="/">

<xsl:apply-templates select="document('asset.xml')//title/txt"/> <!--- this
uses an external asset.xml which contains your text --->

<xsl:apply-templates select="title/txt"/> <!--- this uses xml which contains
your text in assoc xml file --->

</xsl:template>

here is the xml either contained in current.xml or asset.xml

<title>
<txt xml:lang="en"><b>test title</b></txt>
<txt xml:lang="de"></txt>
<txt xml:lang="fr"></txt>
<txt xml:lang="it"></txt>
</title>

local styling can occur in the stylesheet or the xml.

b) the same technique as a can be used, but u may find that some languages
take up more space then others.

c) i would definately say to preparse everything, as trying to in realtime
dynamically present a site in its language takes too much time, sooooo u
would have an individual directory for each language version.

good luck

cheers, jim fuller


----- Original Message -----
From: "Annalisa Ricci" <Annalisa.Ricci@xxxxxxxx>
To: <xsl-list@xxxxxxxxxxxxxxxxxxxxxx>
Sent: Tuesday, November 13, 2001 10:17 AM
Subject:  Globalization with XSL-XML


> Hi all,
>
> I would know your opinion about the handling
> of multilinguistic Web sites with XML and XSL.
>
> For example, are they convenient for handling Web applications
> (see Input Forms) that can dynamically change their display, adapting
> themselves to different languages and countries?
> And how to handle multilanguage inputs?
>
> Why to choose XML-XSL and not, for ex., the Java properties?
>
> There is someone that could tell me his opinion and/or redirect me to
> a web site?
>
> TIA,
>            Annalisa
>
>
>  XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
>


 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

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.
Email
First Name
Last Name
Company
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.