diff --git a/lib/common.lib.php b/lib/common.lib.php index a7011c249..4b8e0d4cc 100644 --- a/lib/common.lib.php +++ b/lib/common.lib.php @@ -33,7 +33,7 @@ function get_microtime() } -// 현재페이지, 총페이지수, 한페이지에 보여줄 행, URL +// 한페이지에 보여줄 행, 현재페이지, 총페이지수, URL function get_paging($write_pages, $cur_page, $total_page, $url, $add="") { $url = preg_replace('#&page=[0-9]*(&page=)$#', '$1', $url); @@ -2604,4 +2604,15 @@ function htmlspecialchars2($str) $str = strtr($str, $trans); return $str; } + +// date 형식 변환 +function conv_date_format($format, $date, $add='') +{ + if($add) + $timestamp = strtotime($add, strtotime($date)); + else + $timestamp = strtotime($date); + + return date($format, $timestamp); +} ?> \ No newline at end of file