rgb192
asked on
specifically why is time different on different servers
<?php
$row->real_timestamp='1392598061';
echo ' '.date("D", $row->real_timestamp);
echo'<br>'.date("M j, g:i A", $row->real_timestamp);
one server has output
Mon
Feb 17, 12:47 AM
another server
Warning: Creating default object from empty value in C:\wamp\www\test\real_time
Sun
Feb 16, 7:47 PM
I have simplified this code because I am selecting mysql field and I have to add different numbers in order to show the real time.
I am looking for a specific reason why this occurs and not a link to php time.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
You can also set the timezone as a PHP initialization setting, which makes sense because the server will rarely change time zones -- they are related to geography.
ASKER
thanks