728x90
$sdate = strtotime("2020-12-16");
$edate = strtotime("2020-12-21");
$days = [];
while(date("Y-m-d", $sdate) < date("Y-m-d", $edate)) {
	if(date("N", $sdate) < 6) $days[] = date("Y-m-d", $sdate);
	$sdate = strtotime("+1 day", $sdate);
}

print_r($days);

 

반응형

댓글 0