shift time...

Des exist a way to shift the time of a server? for example my server is
in California but my time in Italy is shifted of 9 hours;
How do I shift the time (in italian time) if I have this function
$data =date("j/n/Y"); ???

Thanks!
lukk3tt0 [ Do, 06 Dezember 2007 19:58 ] [ ID #1887281 ]

Re: shift time...

lukk3tt0 wrote:
> Des exist a way to shift the time of a server? for example my server is
> in California but my time in Italy is shifted of 9 hours;
> How do I shift the time (in italian time) if I have this function
> $data =date("j/n/Y"); ???

In the head of your scripts add

date_default_timezone_set("Europe/Rome");

Then all date/time functions after this will be using "italian" time instead
of the "pacific" time.


--

//Aho
Shion [ Do, 06 Dezember 2007 21:23 ] [ ID #1887282 ]

Re: shift time...

Il Thu, 06 Dec 2007 21:23:08 +0100, J.O. Aho ha scritto:


>
> date_default_timezone_set("Europe/Rome");

Tnx a lot!!!
lukk3tt0 [ Fr, 07 Dezember 2007 19:38 ] [ ID #1888104 ]

Re: shift time...

Post removed (X-No-Archive: yes)
Notifier Deamon [ Fr, 07 Dezember 2007 20:18 ] [ ID #1888105 ]
PHP » alt.php » shift time...

Vorheriges Thema: Re: Script running under Command Prompt or Browser or some other application?
Nächstes Thema: single quote in string constant