날짜(date)의 한글요일 구하기 > PHP

본문 바로가기

사이트 내 전체검색

뒤로가기 PHP

날짜(date)의 한글요일 구하기

페이지 정보

작성자 관리자 작성일 20-12-24 09:50 조회 8,272 댓글 0

본문

function find_week($date) {
  $week_array = array("일","월","화","수","목","금","토");
  $week_print = $week_array[date('w', strtotime($date))];
  return $week_print;
}

echo find_week('2020-12-25');

댓글목록 0

등록된 댓글이 없습니다.

Copyright © neion.co.kr All rights reserved.
PC 버전으로 보기