3v4l.org

run code in 300+ PHP versions simultaneously
<?php $dateInput = DateTime::createFromFormat('ymd', '170621'); $now = new Datetime(); $lastWeek = new DateTime("-1 week"); var_dump($dateInput); var_dump($lastWeek); var_dump($dateInput >= $lastWeek && $now >= $dateInput);
Output for git.master
object(DateTime)#1 (3) { ["date"]=> string(26) "2017-06-21 08:45:27.000000" ["timezone_type"]=> int(3) ["timezone"]=> string(16) "Europe/Amsterdam" } object(DateTime)#3 (3) { ["date"]=> string(26) "2017-06-22 08:45:27.003460" ["timezone_type"]=> int(3) ["timezone"]=> string(16) "Europe/Amsterdam" } bool(false)
Output for git.master_jit
object(DateTime)#1 (3) { ["date"]=> string(26) "2017-06-21 08:45:27.000000" ["timezone_type"]=> int(3) ["timezone"]=> string(16) "Europe/Amsterdam" } object(DateTime)#3 (3) { ["date"]=> string(26) "2017-06-22 08:45:27.003829" ["timezone_type"]=> int(3) ["timezone"]=> string(16) "Europe/Amsterdam" } bool(false)
Output for rfc.property-hooks
object(DateTime)#1 (3) { ["date"]=> string(26) "2017-06-21 08:45:27.000000" ["timezone_type"]=> int(3) ["timezone"]=> string(16) "Europe/Amsterdam" } object(DateTime)#3 (3) { ["date"]=> string(26) "2017-06-22 08:45:27.003805" ["timezone_type"]=> int(3) ["timezone"]=> string(16) "Europe/Amsterdam" } bool(false)

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:
65.74 ms | 401 KiB | 8 Q