Created
February 11, 2019 20:03
-
-
Save arkadiusjonczek/74c8a44d24c32ed486ef58e94b8e6747 to your computer and use it in GitHub Desktop.
convert UTC datetime to local timezone #tags: PHP
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
date_default_timezone_set('Europe/Berlin'); | |
$time = strtotime('2019-02-10 22:38:20 UTC'); | |
$dateInLocal = date("Y-m-d H:i:s", $time); | |
print_r($dateInLocal); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment