tapestry-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ted Steen <ted.st...@gmail.com>
Subject Re: simple localization question
Date Thu, 01 Sep 2005 21:48:07 GMT
If you write "message:page.error" tapestry will look for a message
called "page.error", that is it will look in your .properties file for
that message.
If you want to dynamically choose the message I think the best thing
would be to do like this:

<span jwcid="@Insert" value="ognl:pageError" />

public String getPageError() {
  return getMessages().getMessage(getMyErrorMessage());
}

This might be a case of blind leading the blind, and I also don't
understand why you would like to do this thing :)

On 9/1/05, Jean-Yves Sironneau <jys@fr.st> wrote:
> Hello,
> 
> I have a simple question, when an error occurs in one of my pages i set
> an attribute to  a string  that  should be localized, but in my template
> i don't konw how to insert it, i tried
> 
>     <span jwcid="@Insert" value="message:page.error"/>
> 
> but the page.error is resolved as a literal, noot an ognl expression.
> 
> 
> Thank you
> 
> Jean-Yves
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
> 
> 


-- 
/ted

---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org


Mime
View raw message