Wrox Home  
Search P2P Archive for: Go

  Return to Index  

servlets thread: Re: Local Date?


Message #1 by "chanoch" <mail@c...> on Tue, 2 Jul 2002 21:14:30 +0100
yes, and you can use the getLocale() method of ServletRequest to retrieve
the locale.

chanoch

----- Original Message -----
From: "Giovanni Cuccu" <gcuccu@d...>
To: "Servlets" <servlets@p...>
Sent: Friday, June 28, 2002 1:09 PM
Subject: [servlets] Re: Local Date?


> Hi
> I usually use this method
> java.text.DateFormat.getDateInstance(DateFormat.FULL,new
> Locale(<>,<>).format(new Date())
> to format the date in the user locale. for example for italian I use "it"
> as the first parameter and "" for the second
> hope it helps,
> Giovanni
> At 13:10 28/06/2002 +0000, you wrote:
> >Hi
> >
> >How do I format my Date to Local Date?
> >
> >I can't use toLocal because this is deprecated so I don't want to use
> >that.
> >
> >If my user is from Sweden it should format the Date to his Local Date.
> >
> >
> >
> >/Henrik
>
>
> ----------------------------------------
> Giovanni Cuccu
> Sw Engineer@d...
> Dianoema S.p.A.
> Via de' Carracci 93 40131 Bologna
> Tel: 051-4193911
> e-mail:gcuccu@d...
> ----------------------------------------
>
>
>
>


  Return to Index