Re: How to display the ' character from a .properties file

2007-07-12 Thread Josh Vickery
On 7/12/07, Niall Pemberton <[EMAIL PROTECTED]> wrote: I don't use Struts2 - but my guess is that this is down to a single quote being an escape character in MessageFormat: http://java.sun.com/j2se/1.4.2/docs/api/java/text/MessageFormat.html So its probably not a bug - just need to escape singl

Re: How to display the ' character from a .properties file

2007-07-12 Thread Niall Pemberton
On 7/12/07, Josh Vickery <[EMAIL PROTECTED]> wrote: Actually, I think this is a bug in the handling of MessageResources in Struts 2. Not only do ' characters in properties files fail to display, they cause parameter substitution to fail. For example, if you have a properties file: I don't use

Re: How to display the ' character from a .properties file

2007-07-12 Thread TonyD
I wrote my string in my .properties file mylabel=Now it''s working and then a got it in my .jsp with Antonio Petrelli-3 wrote: > > 2007/7/12, TonyD <[EMAIL PROTECTED]>: >> >> >> Thanks it works! > > > > > Mmm... this means that there's something wrong when you display the text. > I th

Re: How to display the ' character from a .properties file

2007-07-12 Thread Josh Vickery
Actually, I think this is a bug in the handling of MessageResources in Struts 2. Not only do ' characters in properties files fail to display, they cause parameter substitution to fail. For example, if you have a properties file: foo=Message's for {0} and you attempt to display it in a jsp lik

Re: How to display the ' character from a .properties file

2007-07-12 Thread Antonio Petrelli
2007/7/12, TonyD <[EMAIL PROTECTED]>: Thanks it works! Mmm... this means that there's something wrong when you display the text. I think that, before writing the string, you have to escape it. How, and where, do you write the string? Antonio

Re: How to display the ' character from a .properties file

2007-07-12 Thread TonyD
Thanks it works! Pascal Lalonde-4 wrote: > > This should be the good solution, that's what we do ... > > [EMAIL PROTECTED] wrote: >> try to double the ' >> >> ex.: >> >> mylabel=I don''t know how >> >> >>> If in my .properties file I have text with the ' character >>> >>> my.properties (fil

Re: How to display the ' character from a .properties file

2007-07-12 Thread Pascal Lalonde
This should be the good solution, that's what we do ... [EMAIL PROTECTED] wrote: try to double the ' ex.: mylabel=I don''t know how If in my .properties file I have text with the ' character my.properties (file) mylabel=I don't know how ... The output doesn't display the ' character

RE How to display the ' character from a .properties file

2007-07-12 Thread MLENEVEUT
I had the same problem, and I put ’ instead of ' in my .properties. Ragards, Michaël TonyD <[EMAIL PROTECTED]> 12/07/2007 14:29 Veuillez répondre à "Struts Users Mailing List" A user@struts.apache.org cc Objet How to display the ' character from a .prope

Re: How to display the ' character from a .properties file

2007-07-12 Thread acogoluegnes
try to double the ' ex.: mylabel=I don''t know how > > If in my .properties file I have text with the ' character > > my.properties (file) > > mylabel=I don't know how > ... > > > The output doesn't display the ' character > > I dont know how > > Do I need a special character before the ' charac

Re: How to display the ' character from a .properties file

2007-07-12 Thread Antonio Petrelli
2007/7/12, TonyD <[EMAIL PROTECTED]>: Do I need a special character before the ' character? Which one? I could say the backslash ( \ ) but the apostrophe is not a special character to be escaped (such as = ! ) so I wonder why you cannot see it... Antonio

How to display the ' character from a .properties file

2007-07-12 Thread TonyD
If in my .properties file I have text with the ' character my.properties (file) mylabel=I don't know how ... The output doesn't display the ' character I dont know how Do I need a special character before the ' character? Which one? Thanks. -- View this message in context: http://www.n