3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $to_date = time("2014-01-02"); // Input your date here e.g. strtotime("2014-01-02") $from_date = strtotime("2012-01-31"); $day_diff = $to_date - $from_date; echo floor($day_diff/(60*60*24)); ?>
Output for 7.3.0 - 7.3.1
Warning: time() expects exactly 0 parameters, 1 given in /in/mcss2 on line 2 -15370
Output for 4.3.0 - 7.2.13
863