Win a copy of Think Java: How to Think Like a Computer Scientist this week in the Java in General forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Bean:message and c:out

 
Tony Smith
Ranch Hand
Posts: 77
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have a bean ${row}
An element of this bean is tranCodeT.
${row.tranCodeT} returns a key that's in my resource property file for i18n-age.

<bean:message...> seems to want a constant key, not something like ${row.tranCodeT}

<c ut...> seems to know nothing about the properties file.

How can I use struts to display the value from the property file?
 
Merrill Higginson
Ranch Hand
Posts: 4864
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
This link explains how to use JSTL with messaging. Basically, you'll want to use <fmt:message> rather than <bean:message> since the <fmt:message> tag accepts an EL value.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic