3v4l.org

run code in 300+ PHP versions simultaneously
<?php $time = array( 'start' => new DateTime('2014-01-27 22:40:40 UTC'), 'end' => new DateTime('2014-01-28 17:40:40 UTC'), 'days' => array(), ); $start = clone $time['start']; $start->setTime(0, 0); $end = clone $time['end']; $end->setTime(0, 0); while ($start <= $end) { $time['days'][] = $start->format("Y-m-d"); $start->modify('+1 day'); } print_r($time);
Output for git.master, git.master_jit, rfc.property-hooks
Array ( [start] => DateTime Object ( [date] => 2014-01-27 22:40:40.000000 [timezone_type] => 3 [timezone] => UTC ) [end] => DateTime Object ( [date] => 2014-01-28 17:40:40.000000 [timezone_type] => 3 [timezone] => UTC ) [days] => Array ( [0] => 2014-01-27 [1] => 2014-01-28 ) )

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:
56.29 ms | 402 KiB | 8 Q