Struts2 i18n java properties, how to avoid characters?

I don't know how to escape 'in the java properties file. I am using struts2 and getText functions to populate i18n and text tags.

For example, I use: config.users.title = taula d'usuaris ---> config.users.title = taula d \ 'usuaris

But in my JSP I get: taula dusuaris.

I use this to display text on my JSP:

<label for="title"><s:text name="config.users.title" />:</label>

Also I sometimes use:

<s:select id="categories"  name="categories"  headerKey="" 
headerValue="%{getText('map.categories.all')}"
list="categories" listKey="id" listValue="name"/>

What mistake?

Thank!

+5
source share
2 answers

Thanks lucentmind and BalusC foryour repliess

The solution was this: in my properties file I quoted “how” and worked fine.

**taula d \''usuaris**

thank

+4
source

escape-, HTML.

propertis : taula d "\" usuaris

0

All Articles