PHP
월말구하기
아마데우스
2008. 11. 5. 16:26
function getMonthEnd($month)
{
if(strlen($month) == 6){
$tmp = substr($month,0,4) .'-'. substr($month,4,2) .'-01';
}else{
$tmp = $month .'-01';
}
$tmp = strtotime("+1 month",strtotime($tmp));
return date("d",strtotime("-1 day",$tmp));
}