I have a project that is mainly based in the CET region. I installed CET in config / app.php, but are all the timestamps in the database stored in UTC?
How can I set a “global” time zone for timestamps?
I did this test:
<?php $timezone = date_default_timezone_get(); echo "The current server timezone is: " . $timezone; echo "<br />".date('m/d/Y h:i:s a', time()); $mytime = Carbon\Carbon::now(); echo "<br />".$mytime->toDateTimeString(); ?>
and here is the result:
The current server timezone is: CET 06/09/2016 12:06:04 pm 2016-06-09 11:06:04
TNX Y
source share