3v4l.org

run code in 300+ PHP versions simultaneously
<?php $currentDateStr = "20/03/2014"; // $bsibooking->checkInDate; $currentDateArray = explode("/", $currentDateStr); $currentDate = new DateTime(); $currentDate->setTimezone(new DateTimeZone('Europe/London')); $currentDate = $currentDate->setDate(intval($currentDateArray[2]), intval($currentDateArray[1]), intval($currentDateArray[0])); print_r($currentDate); ?>
Output for git.master
DateTime Object ( [date] => 2014-03-20 14:09:15.003886 [timezone_type] => 3 [timezone] => Europe/London )
Output for git.master_jit
DateTime Object ( [date] => 2014-03-20 14:09:15.004095 [timezone_type] => 3 [timezone] => Europe/London )
Output for rfc.property-hooks
DateTime Object ( [date] => 2014-03-20 14:09:15.006884 [timezone_type] => 3 [timezone] => Europe/London )

This tab shows result from various feature-branches currently under review by the php developers. Contact me to have additional branches featured.

Active branches

Archived branches

Once feature-branches are merged or declined, they are no longer available. Their functionality (when merged) can be viewed from the main output page


preferences:
37.26 ms | 401 KiB | 8 Q