AW: Testing I18n.

2003-02-04 Thread Hirschmann, Bernhard

Joni, if you want to change the locale depending on the user logging in to
the application, you can use the 
setLocale (javax.servlet.http.HttpServletRequest request, java.util.Locale
locale) 
in your Struts action class. This overrides the default locale of the
browser.

Regards,
Bernhard


-Ursprüngliche Nachricht-
Von: Taylor Cowan
Gesendet: Mittwoch, 5. Februar 2003 09:42
An: Struts Users Mailing List
Betreff: Re: Testing I18n.


Struts can detect the client's prefered language by using the
"accept-languages" header value.  You can do this on IE by selecting
Tools>Internet Options>Languages and choosing Chinese as your preferred
language.

Then from within an action you can retrieve the locale with
"getLocale(req)".  Note that i18n in struts is different from swing in that
you must always tell the java.text and util classes which locale to use.
The default locale of the server may not be what the user wants.  Is that
what you meant by
"make struts to think that this application runs on Chinese/German locale"?


Taylor Cowan

- Original Message -
From: "joni santoso"
To: "Struts Users Mailing List" <[EMAIL PROTECTED]>
Sent: Tuesday, February 04, 2003 9:00 PM
Subject: Testing I18n.


> Hi,
>
> I am using Win2kServer using English version. I wanna test
> the i18n support from struts. I want to create an app
> using Chinese and German language. How to emulate it using
> struts? I mean how to make struts to think that this
> application runs on Chinese/German locale.
>
> Regards,
>
>
>

===
> Meriahkan Hari Kasih Sayang dengan mengirimkan Kartu Elektronik PlasaCom
kepada kerabat dan teman yang Anda kasihi !
> Kepada para pengguna TELKOMSave, lakukan pergantian kartu lama Anda segera
! http://www.telkomsave.com
>

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


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

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




Re: Testing I18n.

2003-02-04 Thread Taylor Cowan
Struts can detect the client's prefered language by using the
"accept-languages" header value.  You can do this on IE by selecting
Tools>Internet Options>Languages and choosing Chinese as your preferred
language.

Then from within an action you can retrieve the locale with
"getLocale(req)".  Note that i18n in struts is different from swing in that
you must always tell the java.text and util classes which locale to use.
The default locale of the server may not be what the user wants.  Is that
what you meant by
"make struts to think that this application runs on Chinese/German locale"?


Taylor Cowan

- Original Message -
From: "joni santoso" <[EMAIL PROTECTED]>
To: "Struts Users Mailing List" <[EMAIL PROTECTED]>
Sent: Tuesday, February 04, 2003 9:00 PM
Subject: Testing I18n.


> Hi,
>
> I am using Win2kServer using English version. I wanna test
> the i18n support from struts. I want to create an app
> using Chinese and German language. How to emulate it using
> struts? I mean how to make struts to think that this
> application runs on Chinese/German locale.
>
> Regards,
>
>
>

===
> Meriahkan Hari Kasih Sayang dengan mengirimkan Kartu Elektronik PlasaCom
kepada kerabat dan teman yang Anda kasihi !
> Kepada para pengguna TELKOMSave, lakukan pergantian kartu lama Anda segera
! http://www.telkomsave.com
>

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


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




Testing I18n.

2003-02-04 Thread joni santoso
Hi,

I am using Win2kServer using English version. I wanna test 
the i18n support from struts. I want to create an app 
using Chinese and German language. How to emulate it using 
struts? I mean how to make struts to think that this 
application runs on Chinese/German locale.

Regards,


===
Meriahkan Hari Kasih Sayang dengan mengirimkan Kartu Elektronik PlasaCom kepada kerabat dan teman yang Anda kasihi !
Kepada para pengguna TELKOMSave, lakukan pergantian kartu lama Anda segera ! http://www.telkomsave.com
===

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