You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by "Hohlen, John" <JH...@erac.com> on 2002/09/20 22:22:03 UTC

Struts 1.1: Key/Value Pairs Common To Multiple Sub-Apps (Message Resource Files)

I'm creating multiple sub-applications as provided through Struts 1.1 (b2).
I have some common error message key/value pairs that need to appear in each
sub-app's respective message resource file.  Does anyone know a way to
centralize these common key/value pairs instead of duplicating them in each
file? Right now, my hoaky solution is to put the common key/value pairs in
their own file and then concatenate them to the end of each sub-app's file
during the ANT build process.  That way I only have to make changes in one
file.  

Some examples would the key/value pairs used with the <html:errors> tag:
errors.header = Correct the following error(s):
errors.footer =
errors.prefix = <li>
errors.suffix = </li> 


Thanks,

JOHN 


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: Struts 1.1: Key/Value Pairs Common To Multiple Sub-Apps (Message Resource Files)

Posted by Eddie Bush <ek...@swbell.net>.
Unfortunately, this is one of the side-effects of each module having 
it's own configuration.  Your solution is sound and should work just 
fine.  Hopefully this will be streamlined before 1.1 final.  There are 
other ... features that arise from each module being wholly independent 
I'm not to wild about either, but we have to bear in mind that 
backward-compatability is pretty important to the community.

Hohlen, John wrote:

>I'm creating multiple sub-applications as provided through Struts 1.1 (b2).
>I have some common error message key/value pairs that need to appear in each
>sub-app's respective message resource file.  Does anyone know a way to
>centralize these common key/value pairs instead of duplicating them in each
>file? Right now, my hoaky solution is to put the common key/value pairs in
>their own file and then concatenate them to the end of each sub-app's file
>during the ANT build process.  That way I only have to make changes in one
>file.  
>
>Some examples would the key/value pairs used with the <html:errors> tag:
>errors.header = Correct the following error(s):
>errors.footer =
>errors.prefix = <li>
>errors.suffix = </li> 
>
>
>Thanks,
>
>JOHN 
>

-- 
Eddie Bush




--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>