Made today the setlocale tag -- I have uploaded the code to Craig.. 
:-)

Max

On 24 Oct 00, at 10:53, Peter Alfors wrote:

> This is a multi-part message in MIME format.
> --------------70C1BF444C3465E3680028F6
> Content-Type: multipart/alternative;
>  boundary="------------656565A9A3AE916757DA7189"
> 
> 
> --------------656565A9A3AE916757DA7189
> Content-Type: text/plain; charset=us-ascii
> Content-Transfer-Encoding: 7bit
> 
> Hello,
> 
> Ciao tutti,
> 
> I have been trying to figure out how to make the <struts:message> tag
> work for
> us (InterAge) while developing multi-language web sites. The problem is
> that we
> want to be able to manually set a language and have all the text in that
> 
> language, from there on (for reasons I won't speculate about), but I
> didn't
> find a way to do it. Sure, you can specify a Locale with the "locale"
> parameter, but it's unnecessarily awkward (and inefficient) way of
> operating if
> we just need to change the language once during a session.
> 
> Btw, I would really like that the "locale" parameter was
> <rtexprvalue>true</rtexprvalue> so we could use a variable to indicate
> the
> locale to use, while now is "false".. Can this be set as a default in
> the main
> struts distribution? If not, is there a reason why? (just asking)
> 
> The question is: did I miss something that could let us set the locale
> once and
> forget about the "locale" parameter in the "message" tag? If not, can I
> go on
> and create a small tag (to be of course donated to the Struts project)
> that
> simply sets the new default locale until further notice?
> 
> From what I could see it is just a matter of setting an object in the
> session
> scope, retrieving the object name with the help of Action.LOCALE_KEY,
> but if
> there is some caveat it'd be great to know. Thanks guys/gals.
> 
> Yep.. Just set the session Action.LOCALE_KEY attribute to what you want
> it to be.
> 
> Or, you could over-ride the 'processLocale' method in the ActionServlet
> class.  We use the new method to check if the 'debug' value is set in
> the web.xml.  If so, then the locale is set the curent request locale.
> This allows our developers to test multiple languages 'on the fly'.
> 
> Pete
> 
> --
> Max
> 
> --------------656565A9A3AE916757DA7189
> Content-Type: text/html; charset=us-ascii
> Content-Transfer-Encoding: 7bit
> 
> <!doctype html public "-//w3c//dtd html 4.0 transitional//en">
> <html>
> Hello,<i></i>
> <p><i>Ciao tutti,</i><i></i>
> <p><i>I have been trying to figure out how to make the &lt;struts:message>
> tag work for</i>
> <br><i>us (InterAge) while developing multi-language web sites. The problem
> is that we</i>
> <br><i>want to be able to manually set a language and have all the text
> in that</i>
> <br><i>language, from there on (for reasons I won't speculate about), but
> I didn't</i>
> <br><i>find a way to do it. Sure, you can specify a Locale with the "locale"</i>
> <br><i>parameter, but it's unnecessarily awkward (and inefficient) way
> of operating if</i>
> <br><i>we just need to change the language once during a session.</i><i></i>
> <p><i>Btw, I would really like that the "locale" parameter was</i>
> <br><i>&lt;rtexprvalue>true&lt;/rtexprvalue> so we could use a variable
> to indicate the</i>
> <br><i>locale to use, while now is "false".. Can this be set as a default
> in the main</i>
> <br><i>struts distribution? If not, is there a reason why? (just asking)</i><i></i>
> <p><i>The question is: did I miss something that could let us set the locale
> once and</i>
> <br><i>forget about the "locale" parameter in the "message" tag? If not,
> can I go on</i>
> <br><i>and create a small tag (to be of course donated to the Struts project)
> that</i>
> <br><i>simply sets the new default locale until further notice?</i><i></i>
> <p><i>From what I could see it is just a matter of setting an object in
> the session</i>
> <br><i>scope, retrieving the object name with the help of Action.LOCALE_KEY,
> but if</i>
> <br><i>there is some caveat it'd be great to know. Thanks guys/gals.</i><i></i>
> <p>Yep.. Just set the session Action.LOCALE_KEY attribute to what you want
> it to be.<i></i>
> <p>Or, you could over-ride the 'processLocale' method in the ActionServlet
> class.&nbsp; We use the new method to check if the 'debug' value is set
> in the web.xml.&nbsp; If so, then the locale is set the curent request
> locale.&nbsp; This allows our developers to test multiple languages 'on
> the fly'.
> <p>Pete
> <p><i>--</i>
> <br><i>Max</i></html>
> 
> --------------656565A9A3AE916757DA7189--
> 
> --------------70C1BF444C3465E3680028F6
> Content-Type: text/x-vcard; charset=us-ascii;
>  name="peter.alfors.vcf"
> Content-Transfer-Encoding: 7bit
> Content-Description: Card for Peter Alfors
> Content-Disposition: attachment;
>  filename="peter.alfors.vcf"
> 
> begin:vcard 
> n:;
> x-mozilla-html:FALSE
> org:<BR><IMG SRC="http://www.irista.com/logo/irista.gif"><BR><BR><FONT 
>Color=#000080><FONT SIZE=2
><B>Bringing Vision to Your Supply Chain
> adr:;;;;;;
> version:2.1
> end:vcard
> 
> --------------70C1BF444C3465E3680028F6--
> 


Reply via email to