Thanks Nick.

2007/8/31, Nick Westgate <[EMAIL PROTECTED]>:
>
> I know it's a bit painful without OGNL, but we have to make do.
> If you can't do it in the template, call a Java method.
> Something like ...
>
> ${userState}
> ...
>
> @Inject
> private Messages messages;
> ...
>
> String getUserState()
> {
>      return messages.get(getUser().getState());
> }
>
> Cheers,
> Nick.
>
>
> Allen Guo wrote:
> > Hi All,
> >
> > I have a question on how to get a dynamic localized key value
> > Below is a scenario
> > [<t:loop source="users" value="_user">
> > ${message:<prop:user.state>}
> > </t:loop>
> >
> > I hope similar codes above can get the localized key from properties
> > file dynamiclly
> > There may be following data in properties file
> >
> > // **_zh_CN.properties
> > california=加利福尼亚
> > indiana=印第安那
> >
> > // **_en_US.properties
> > california=Califonia
> > indiana=Indiana
> >
> >
> > Any ideas?
> >
> > Cheers
> > Guoguo Long
> >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> >
> >
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>

Reply via email to