I'm trying to get multiple language support to work. I have created two files, ofmResources.properties and ofmResources_de.properties and stored them in WEB-INF/classes.
In web.xml I have:
... <init-param> <param-name>application</param-name> <param-value>ofmResources</param-value> </init-param> ...
...as an init parameter of ActionServlet. Then, in a particular action I need to return a message to the view, so I do this:
MessageResources mr = getResources(request); myActionForm.setMessage(mr.getMessage("messages.deleteFailed"));
Now, this works just fine. My message is displayed as a result of the onLoad event of my page via a simple JavaScript alert box. Very cool.
However, if I want to display the message from the German resource file, I can't get it to work. I thought all I had to do was this:
myActionForm.setMessage(mr.getMessage("de", "messages.deleteFailed"));
...but it always seems to return null. I am expecting that the framework will, in simplest terms, just append _de to the "ofmResources" value of the application init param, and therefore get the messages.deleteFailed value out of that file rather than the default ofmResources.properties file.
Am I nuts or should it not work that way? If I'm nuts (or nutier than normal :) ), then how does one get this to work? If I'm not nuts, any ideas why what I'm doing doesn't work? Thanks all!
_________________________________________________________________
Best Restaurant Giveaway Ever! Vote for your favorites for a chance to win $1 million! http://local.msn.com/special/giveaway.asp
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]