• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

ApplicationResources is not being read

 
Ranch Hand
Posts: 91
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I am new to Struts 2 and am trying to execute the tutorial in the below link.
http://java.dzone.com/articles/struts2-tutorial-part-27

Everything works fine, but the labels given in ApplicationResources.properties are not being picked, so the page loads with text boxes and buttons with no label text. Dont see any errors in the tomcat console. I have the tutorial line by line, double checked for typos and the entry in struts.xml

<constant name="struts.custom.i18n.resources" value="ApplicationResources" />

Any ideas what I am missing ?

Cheers,
Ram
 
Ranch Hand
Posts: 122
Mac IntelliJ IDE Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
with so little to go off of, I would guess than maybe your resources src file is not getting deployed to the classes directory of the WAR. To do a sanity check just put the struts.xml and that resources file in the src directory and try again. That would be my only guess. You can also turn on trace to make sure those resources got loaded.
 
Ram Murthy
Ranch Hand
Posts: 91
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks, the file was having an extra space in the front.
 
reply
    Bookmark Topic Watch Topic
  • New Topic