How can I echo all dates for mondays/ wednesday / friday between these two dates?
This is what I have been working with:
function get_days ( $s, $e )
{
$r = array ();
$s = strtotime ( $s . ' GMT' );
$e = strtotime ( $e . ' GMT' );
$day = gmdate ( 'l', $s );
do
{
$r[] = $day . ', ' . gmdate ( 'Y-m-d', $s );
$s += 86400 * 7;
} while ( $s <= $e );
return $r;
}
print_r ( get_days ( $start, $end ) );
Try this: