sat2_waran said the following on 15/6/06 11:31:
Hi
We are using Cocoon 2.1(Web publishing Framework)

We have some problem in getting the i18n content in pages.

If we hardcode the key value like for instance,
<i18n:text>input-text</i18n:text> then the translated value is getting
printed (for example “output-text”),

For Example: input-text is ‘home’ corresponding value is ‘Espana’ in
message.xml [ <message key=”home”>Espana</message>]

 But if we try to  get  the key value from xsl variable, like

<i18n:text><xsl:value-of select=”$variable”/></i18n:text> it’s not working
although the $variable contains the value as ‘home’. The output comes as
“home”.

But the expected result is ‘Espana’

Could you please help us to resolve this problem?

We will be very grateful to you if you could help us as soon as possible.

I've seen this question recently. Two suggestions where made that would be the first I would look into:

1. is the i18n transformation done AFTER your xsl transformation that solves the "value-of $variable"?

2. comment out all transformations after this xsl transformation and just serialize it to xml to check if you actually get <i18n:text>home</i18n:text>

I suspect the first suggestion solves your problem.

Finally, if none of these work, check that "message.xml" is actually used, not FormsMessages.xml or OtherMessages.xml.

HTH

Bye, Helma

Reply via email to