Re: Time zone problem in php

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On  the line of  $seconds =  change the number to the number
hours  India is from GMT


$localdate  will be displayed as  08/06/07
$localtime will be dislalyed as HH:MM:SS TMZ

TMZ  meaning Time zone

Hope this helps





$timestamp=time();
$seconds = 5*60*60;   { change the  5  to the number of hours from GMT}
$timestamp-=$seconds;
$localtime = date("m/d/y G:i:s",$timestamp);

$localdate = substr($localtime,0,8);
$localtime = substr($localtime,9,8);





--- In php-objects@xxxxxxxxxxxxxxx, "edward_e09" <edward_e09@...> 
wrote:
>
> Hi
> 
> I'm using time and date functions in a programme in php. But my 
problem 
> is its not showing the correct time accord to our india.
> 
> Can anybody solved this or come across before. Please help me out of 
> this.
> 
> Thank you.
>



[Index of Archives]     [PHP Home]     [PHP Users]     [PHP Soap]     [Kernel Newbies]     [Yosemite]     [Yosemite Campsites]

  Powered by Linux