3v4l.org

run code in 300+ PHP versions simultaneously
<?php $output = []; for ($day = 0; $day < 21; $day++) { $output[] = strtotime(sprintf('+%d days', $day)); } echo "<select name='days'>"; foreach ($output as $day) { echo "<option value='".$day."'>".date('l jS \of F Y', $day)."</option>"; } echo "</select>";
Output for 7.2.0 - 7.2.33, 7.3.0 - 7.3.33, 7.4.0 - 7.4.33, 8.0.0 - 8.0.30, 8.1.0 - 8.1.31, 8.2.0 - 8.2.26, 8.3.0 - 8.3.14, 8.4.1
<select name='days'><option value='1598406849'>Wednesday 26th of August 2020</option><option value='1598493249'>Thursday 27th of August 2020</option><option value='1598579649'>Friday 28th of August 2020</option><option value='1598666049'>Saturday 29th of August 2020</option><option value='1598752449'>Sunday 30th of August 2020</option><option value='1598838849'>Monday 31st of August 2020</option><option value='1598925249'>Tuesday 1st of September 2020</option><option value='1599011649'>Wednesday 2nd of September 2020</option><option value='1599098049'>Thursday 3rd of September 2020</option><option value='1599184449'>Friday 4th of September 2020</option><option value='1599270849'>Saturday 5th of September 2020</option><option value='1599357249'>Sunday 6th of September 2020</option><option value='1599443649'>Monday 7th of September 2020</option><option value='1599530049'>Tuesday 8th of September 2020</option><option value='1599616449'>Wednesday 9th of September 2020</option><option value='1599702849'>Thursday 10th of September 2020</option><option value='1599789249'>Friday 11th of September 2020</option><option value='1599875649'>Saturday 12th of September 2020</option><option value='1599962049'>Sunday 13th of September 2020</option><option value='1600048449'>Monday 14th of September 2020</option><option value='1600134849'>Tuesday 15th of September 2020</option></select>

preferences:
93.06 ms | 411 KiB | 5 Q