- array_map: documentation ( source)
- date: documentation ( source)
- strtotime: documentation ( source)
- range: documentation ( source)
- array_walk: documentation ( source)
<?php
$start = '10-01-2019';
$end = '21-02-2019';
// This is to progress the range through each day.
// 24 days, 60 minutes, 60 seconds
$step = 24 * 60 * 60;
$days = array_map(function ($day) {
return date('d-M-Y', $day);
}, range(strtotime($end), strtotime($start), -$step));
array_walk($days, function ($day) {
echo $day."\n";
});