Skopik Pavel wrote: > I want to use gentext for generating localized name strings for navigation > tabs in our web help. For now it applies only to index tab. > In my stylesheet I use this template call to generate approriate language > string for index. > <xsl:if test="$generate.webhelp.index != 0"> > <td> > <a href="#" rel="tab3" id="t3"> > <img src="images/iview.gif"/> > <xsl:call-template name="gentext"> > <xsl:with-param name="key" select="'index'" /> > </xsl:call-template> > </a> > </td> > </xsl:if> > > Nevertheless I do not get string for index in Czech but rather in English.
What is the current node for this piece of XSLT? gentext template
computes language for the current node, when there is no current node or
it is "wrong" you will get default language (en). You can try something
like:
<xsl:call-template name="gentext">
<xsl:with-param name="key" select="..."/>
<xsl:with-param name="lang">
<xsl:call-template name="l10n.language">
<xsl:with-param name="target" select="/"/> <!-- or any other
expression which will return node which has proper language set or
inherited -->
</xsl:call-template>
</xsl:with-param>
</xsl:call-template>
--
------------------------------------------------------------------
Jirka Kosek e-mail: [EMAIL PROTECTED] http://www.kosek.cz
------------------------------------------------------------------
Profesionální školení a poradenství v oblasti technologií XML.
Podrobný přehled školení http://xmlguru.cz/skoleni/
------------------------------------------------------------------
Nejbližší termíny školení:
** XSLT 16.-19.9.2008 ** XML schémata 21.-23.10. **
** XSL-FO 18.-19.11.2008 ** XML pro vývojáře 16.-18.12. **
------------------------------------------------------------------
http://docbook.cz Stránky o dokumentačním formátu DocBook
http://xmlguru.cz Blog mostly about XML for English readers
------------------------------------------------------------------
signature.asc
Description: OpenPGP digital signature
