You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Thad Humphries <th...@mindwrap.com> on 2004/02/18 20:32:43 UTC
Tiles and message-resources
Is there any way to for a tlles definition to take a value from the
message-resources file? For example, if I wanted only one file to control my
applications text, could
<tiles:put name="title" value="Page Title" />
pull the value from the message-resources file like a JSP would do.
---------------------------------------------------------------------
To unsubscribe, e-mail: struts-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: struts-user-help@jakarta.apache.org
Re: Tiles and message-resources
Posted by Nadeem Bitar <na...@izucode.com>.
You can internationalize your tiles definitions. In the localized
version you only override the localized strings.
Example
tiles-defs.xml
<definition name=".home" extends=".mainLayout">
<put name="title" value="Homepage"/>
<put name="content" value="somejsp.jsp"/>
<put name="leftCol" value="anotherjsp.jsp"/>
</definition>
and inside tiles-defs_ja.xml you only override title
<definition name=".home" extends".mainLayout">
<put name="title" value="Japanese Homepage Title"/>
</definition>
On Wed, 2004-02-18 at 14:32 -0500, Thad Humphries wrote:
> Is there any way to for a tlles definition to take a value from the
> message-resources file? For example, if I wanted only one file to control my
> applications text, could
>
> <tiles:put name="title" value="Page Title" />
>
> pull the value from the message-resources file like a JSP would do.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: struts-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: struts-user-help@jakarta.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: struts-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: struts-user-help@jakarta.apache.org