cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Piroumian Konstantin <KPiroum...@protek.com>
Subject RE: i18n transformer problem II
Date Mon, 26 Aug 2002 09:03:05 GMT
> From: Dr. Hans M. Rupp [mailto:hans-michael.rupp@danet.de] 
> 
> Ok
> 
> what I get before i18n  (using a pre_i18n view)
> 
> <i18n:text i18n:key="x2">TEMPERATURE_CURRENT</i18n:text>
> this originates from the "master"-stylesheet and is translated by the
> transformer correctly.
> 
> further down in the file:
> <i18n:text i18n:key="x2">TEMPERATURE_CURRENT</i18n:text>
> this originated from a named template in  included 
> stylesheet. This is not
> translated.
> 
> To me those two lines look exactly the same.

Absolutely. Except that they can be mapped to different namespaces depending
on their parent elements. Check that you don't have anything like <bla
xmlns:i18n="something wrong" /> wrapping the second result.

> 
> Any ideas??

No other ideas. If you send relevant files then I'll try to find out what's
wrong.

Konstantin

> 
> This is really driving me nuts. :-(
> 
> Many thanks,
> 
> Hans
> 
> 
> 
> Piroumian Konstantin wrote:
> 
> > > From: Dr. Hans M. Rupp [mailto:hans-michael.rupp@danet.de]
> > ...
> > >
> > > And the i18n tags in the main stylesheet are all processed
> > > correctly, only
> > > those coming from the included stylesheet with the named 
> template are
> > > ignored.
> >
> > Try to remove the i18n transformer from the pipeline and 
> serialize as XML to
> > see what is the output. Maybe there are problems with the 
> namespace that
> > comes from another stylesheet. Maybe the namespace is 
> redeclared for the
> > i18n prefix and i18n transformer does not process them?
> >
> > Konstantin
> >
> > >
> > > Many thanks,
> > >
> > > Hans
> > >
> > > Piroumian Konstantin wrote:
> > >
> > > > > From: Dr. Hans M. Rupp [mailto:hans-michael.rupp@danet.de]
> > > > >
> > > > > Hallo!
> > > > >
> > > > > When have the following problem.
> > > > > i18n tags which are included in xsl templates which
> > > produce the main
> > > > > body of the html output are processed correctly.
> > > > > However at some times I want to call a named template which is
> > > > > physically located in a different xsl file to produce the
> > > > > right i18n tag
> > > > > like:
> > > > >
> > > > > <xsl:template name="MapWeatherCriterionEnum">
> > > > >  <xsl:param name="constant" />
> > > > >  <xsl:variable name="enumType" 
> select="'WeatherCriterionEnum'" />
> > > > >  <xsl:choose>
> > > > >   <xsl:when test="$constant='WEATHER'"><i18n:text
> > > > >
> > > 
> i18n:key="WeatherCriterionEnum.WEATHER">WEATHER</i18n:text></xsl:when>
> > > > >   <xsl:when test="$constant='TEMPERATURE_CURRENT'"><i18n:text
> > > > > i18n:key="WeatherCriterionEnum.TEMPERATURE_CURRENT">TEMPERATUR
> > > > > E_CURRENT</i18n:text></xsl:when>
> > > > >
> > > > > .......
> > > > >
> > > > > The i18n tags produced by named templates are never touched
> > > > > by the i18n
> > > > > Transformer!
> > > >
> > > > This can mean only that i18n transformer is not present in
> > > your pipeline.
> > > > You should run i18n transformer after the XSLT
> > > transformation. Check your
> > > > sitemap.
> > > >
> > > > Konstantin
> > > >
> > > > >
> > > > > The output before i18n:
> > > > >
> > > > > <td class="Text"><i18n:text
> > > > > i18n:key="WeatherCriterionEnum.TEMPERATURE_CURRENT">TEMPERATUR
> > > > > E_CURRENT</i18n:text></td>
> > > > >
> > > > > output after i18n:
> > > > >
> > > > > <td class="Text">
> > > > > <i18n:text
> > > > > i18n:key="WeatherCriterionEnum.TEMPERATURE_CURRENT">TEMPERATUR
> > > > > E_CURRENT</i18n:text>
> > > > >
> > > > > </td>
> > > > >
> > > > > We use Cocoon 2.03
> > > > >
> > > > > I would be gratefull for any ideas.
> > > > >
> > > > > Many thanks,
> > > > >
> > > > > Hans
> > > > >
> > > > >
> > > > > --------------------------------------------
> > > > > Dr. Hans M. Rupp
> > > > > danet Internet Solutions GmbH
> > > > > Waldburgstr. 17-19
> > > > > 70563 Stuttgart
> > > > > Germany
> > > > >
> > > > > Fon +49 711 133 53 50
> > > > > Fax +49 711 133 53 53
> > > > >
> > > > > ------------------------------------------
> > > > >
> > > > >
> > > > >
> > > > >
> > > 
> ---------------------------------------------------------------------
> > > > > Please check that your question  has not already been
> > > answered in the
> > > > > FAQ before posting.
> > > <http://xml.apache.org/cocoon/faq/index.html>
> > > > >
> > > > > To
> > > unsubscribe, e-mail:     <cocoon-users-unsubscribe@xml.apache.org>
> > > > > For additional commands, e-mail:
> > > <cocoon-users-help@xml.apache.org>
> > > > >
> > > >
> > > >
> > > 
> ---------------------------------------------------------------------
> > > > Please check that your question  has not already been
> > > answered in the
> > > > FAQ before posting.
> > > <http://xml.apache.org/cocoon/faq/index.html>
> > > >
> > > > To
> > > unsubscribe, e-mail:     <cocoon-users-unsubscribe@xml.apache.org>
> > > > For additional commands, e-mail:
> > > <cocoon-users-help@xml.apache.org>
> > >
> > > --
> > > --------------------------------------------
> > > Dr. Hans M. Rupp
> > > danet Internet Solutions GmbH
> > > Waldburgstr. 17-19
> > > 70563 Stuttgart
> > > Germany
> > >
> > > Fon +49 711 133 53 50
> > > Fax +49 711 133 53 53
> > >
> > > ------------------------------------------
> > >
> > >
> > >
> > > 
> ---------------------------------------------------------------------
> > > Please check that your question  has not already been 
> answered in the
> > > FAQ before posting.     
> <http://xml.apache.org/cocoon/faq/index.html>
> > >
> > > To 
> unsubscribe, e-mail:     <cocoon-users-unsubscribe@xml.apache.org>
> > > For additional commands, e-mail:   
> <cocoon-users-help@xml.apache.org>
> > >
> >
> > 
> ---------------------------------------------------------------------
> > Please check that your question  has not already been 
> answered in the
> > FAQ before posting.     
> <http://xml.apache.org/cocoon/faq/index.html>
> >
> > To 
> unsubscribe, e-mail:     <cocoon-users-unsubscribe@xml.apache.org>
> > For additional commands, e-mail:   
> <cocoon-users-help@xml.apache.org>
> 
> --
> --------------------------------------------
> Dr. Hans M. Rupp
> danet Internet Solutions GmbH
> Waldburgstr. 17-19
> 70563 Stuttgart
> Germany
> 
> Fon +49 711 133 53 50
> Fax +49 711 133 53 53
> 
> ------------------------------------------
> 
> 
> 
> ---------------------------------------------------------------------
> Please check that your question  has not already been answered in the
> FAQ before posting.     <http://xml.apache.org/cocoon/faq/index.html>
> 
> To unsubscribe, e-mail:     <cocoon-users-unsubscribe@xml.apache.org>
> For additional commands, e-mail:   <cocoon-users-help@xml.apache.org>
> 

---------------------------------------------------------------------
Please check that your question  has not already been answered in the
FAQ before posting.     <http://xml.apache.org/cocoon/faq/index.html>

To unsubscribe, e-mail:     <cocoon-users-unsubscribe@xml.apache.org>
For additional commands, e-mail:   <cocoon-users-help@xml.apache.org>


Mime
View raw message