You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by "Gamble, Wesley (WG10)" <WG...@tmw.com> on 2008/05/27 19:41:36 UTC

Resource bundle location

I can't seem to get my action-specific resource bundle to be found.

 

My action class is in the com.tmw.applicant.tracking.actions package.
It is named ApplicationStartAction.  

 

Should my resource bundle be named "ApplicationStart.properties" or
"ApplicationStartAction.properties"?

Should it be located in the root of the classes directory or in the
com.tmw.applicant.tracking.actions package?

 

FWIW, I have successfully retrieved messages from a global resource
bundle in this app.  But I'd like to have the option of specifying
action specific resources.

 

Thanks,

Wes 


RE: Resource bundle location

Posted by "Gamble, Wesley (WG10)" <WG...@tmw.com>.
I placed my bundle in the action's package with the name
ApplicationStartAction.properties.  However, it is not being seen on the
render.

Does the fact that I'm using Tiles interfere with resource bundle
resolution at all?  I don't think it should, but not sure.

Thanks,
Wes

-----Original Message-----
From: Gamble, Wesley (WG10) [mailto:WG10@tmw.com] 
Sent: Tuesday, May 27, 2008 12:42 PM
To: user@struts.apache.org
Subject: Resource bundle location

I can't seem to get my action-specific resource bundle to be found.

 

My action class is in the com.tmw.applicant.tracking.actions package.
It is named ApplicationStartAction.  

 

Should my resource bundle be named "ApplicationStart.properties" or
"ApplicationStartAction.properties"?

Should it be located in the root of the classes directory or in the
com.tmw.applicant.tracking.actions package?

 

FWIW, I have successfully retrieved messages from a global resource
bundle in this app.  But I'd like to have the option of specifying
action specific resources.

 

Thanks,

Wes 


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


RE: Resource bundle location

Posted by "Gamble, Wesley (WG10)" <WG...@tmw.com>.
ANSWER:

The action class must extend com.opensymphony.xwork2.ActionSupport in
order to get the default resource bundle look-up functionality, which
will allow resources in <Action Name>.properties and <Action
Name>_locale.properties to be loaded.

Wes 

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org