3v4l.org

run code in 300+ PHP versions simultaneously
<?php $date=date_create("2018-02-20 06:54:57"); echo date_format($date,"Y-m-d H:i:s"); echo "\n"; $tz=timezone_open("Asia/Kolkata"); date_timezone_set($date, $tz); echo date_format($date,"Y-m-d H:i:s");
Output for 7.1.0 - 7.1.33, 7.2.0 - 7.2.33, 7.3.0 - 7.3.31, 7.4.0 - 7.4.33, 8.0.0 - 8.0.12, 8.0.14 - 8.0.30, 8.1.0 - 8.1.27, 8.2.0 - 8.2.17, 8.3.0 - 8.3.4
2018-02-20 06:54:57 2018-02-20 11:24:57
Output for 7.3.32 - 7.3.33, 8.0.13
2018-02-20 06:54:57 2018-02-20 12:24:57

preferences:
182.23 ms | 401 KiB | 184 Q