3v4l.org

run code in 300+ PHP versions simultaneously
<?php$day = 'saturday';$step = 2;$unit = 'W';$start = new DateTime();$end = clone $start;$start->modify($day); // Move to first occurence$end->add(new DateInterval('P1Y')); // Move to 1 year from start$interval = new DateInterval("P{$step}{$unit}");$period = new DatePeriod($start, $interval, $end);foreach ($period as $date) { echo $date->format('D, d M Y'), PHP_EOL;}

This is an error 404

There are `0` results


preferences:
147.97 ms | 1399 KiB | 7 Q