[PHP] 날짜별 코드 정리
·
Development
// 날짜 (ex. 1시간 전, 1분 전, 1초 전, 어제, 1일 전, 1주 전, 1개월 전) $strDate = ""; if(substr_count($strDate, '시간 전')) { $intTime = trim( addslashes(strip_tags(str_replace("시간 전","",$strDate)))); $strDate = Date('Ymd',mktime(date('H')-$intTime,0,0,date('m'),date('d'),date('y'))); } else if(substr_count($strDate, '분 전')) { $intTime = trim( addslashes(strip_tags(str_replace("분 전","",$strDate)))); $strDate = Date(..