3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $dt = new \DateTime(); $dr = clone $dt; $ds = clone $dt; $dr->modify('last Saturday'); $ds->modify('this Saturday'); echo $dr->format('Y-m-d'); echo "\n"; echo $dt->format('Y-m-d');
based on Ul9c1
Output for 5.6.0 - 7.3.0rc4
2016-09-10 2016-09-13