Ray Clough wrote:
How do I get the Struts properties from within my application.  What I am

Depends which version of Struts you're using.

looking for is to read the property "struts.custom.i18n.resources", which is
defined in the 'struts.properties' file, so that I can get the
ResourceBundle names.  I guess that there is a Struts Properties object
which can be referenced and read, the question is how.

For Struts 1, use the Action.getResources() methods to get the resource bundle, then retrieve the specific property you want from that.

For Struts 2, use the ActionSupport.getText() methods to retrieve the property directly.

Also, although this is not a Struts question, how do I resolve the suffix on
a ResourceBundle to the language name?

I'm not sure what you mean. Usually, you take a resource bundle name and a locale to locate the most locale-specific resource bundle. Are you trying to derive a locale from a resource bundle file name?

L.


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to