You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Franz Wong <fr...@gmail.com> on 2010/08/09 05:14:46 UTC
Get i18n text problem
Hi group,
In the jsp page, I have a page scope variable "title". This variable stores
the key of the resource bundle. I can print the value by <%= title %>.
However, I am not able to use it with <s:text/>.
I have tried <s:text name="${title}"/> or <s:text name="<%= title %>"/>. But
both of them do not work.
Thanks.
Franz
Re: Get i18n text problem
Posted by Michal Ciasnocha <mc...@struts.cz>.
Hi Franz,
you can use tag <s:property value="getText(title)" /> for text
translation (where "title" is name of your variable).
Best regards,
Michal
Franz Wong wrote on 9.8.2010 5:14:
> Hi group,
>
> In the jsp page, I have a page scope variable "title". This variable stores
> the key of the resource bundle. I can print the value by<%= title %>.
> However, I am not able to use it with<s:text/>.
>
> I have tried<s:text name="${title}"/> or<s:text name="<%= title %>"/>. But
> both of them do not work.
>
> Thanks.
> Franz
>