3v4l.org

run code in 300+ PHP versions simultaneously
<?php $created_at = new \DateTime("2014-12-01 16:58:23"); $sixWeeks = new \DateInterval('P6W'); if($created_at->add($sixWeeks) < new \DateTime()){ echo "Six weeks has passed!\n"; } else echo "Not yet!\n"; $created_at = new \DateTime("2014-10-01 16:58:23"); if($created_at->add($sixWeeks) < new \DateTime()){ echo "Six weeks has passed!\n"; } else echo "Not yet!\n";
Output for git.master, git.master_jit, rfc.property-hooks
Not yet! Six weeks has passed!

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:
31.21 ms | 405 KiB | 5 Q