3v4l.org

run code in 500+ PHP versions simultaneously
<?php $start = '2022-09-10T00:00:00-07:00'; //TZ=-7:00 $timeStamp = strtotime($start); echo "start as UTC: ".gmdate(DATE_W3C,$timeStamp)."\n"; //start as UTC: 2022-09-10T07:00:00+00:00 date_default_timezone_set('Europe/Berlin'); //my local timezone echo "start as Localtime: ".date(DATE_W3C,$timeStamp)."\n"; //start as Localtime: 2022-09-10T09:00:00+02:00

preferences:
86.58 ms | 1263 KiB | 5 Q