3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $today = new DateTime("now"); $date_end = new DateTime('2016-12-15'); $interval = $today->diff($date_end); if($interval->days == "365"){ echo "yes"; }
based on Z91JO
Output for 5.3.20 - 5.4.45, 5.6.28, 7.0.20 - 7.2.0
yes
Output for 5.5.24 - 5.6.21, 7.0.0 - 7.0.6