스킨은 위 링크 클릭
관리자님이 올려주신 스킨인데요
이걸 월요일부터 출력되게 할려면 어딜 수정해야 되나요.
skin/board/schedule/schedule.php
Copy
...<table width='100%' border='0' id='schedule_list'> <?// 오늘$today = getdate($g4[server_time]); $year = (int)substr($schedule_ym, 0, 4);$month = (int)substr($schedule_ym, 4, 2);if ($year < 1) $year = $today[year];if ($month < 1 || $month > 12) $month = $today[mon];$current_ym = sprintf("%04d%02d", $year, $month); $end_day = array(1=>31, 28, 31, 30 , 31, 30, 31, 31, 30 ,31 ,30, 31);// 윤년 계산 부분이다. 4년에 한번꼴로 2월이 28일이 아닌 29일이 있다.if( $year%4 == 0 && $year%100 != 0 || $year%400 == 0 ) $end_day[2] = 29; // 조건에 적합할 경우 28을 29로 변경 // 해당월의 1일을 mktime으로 변경$mktime = mktime(0,0,0,$month,1,$year);$mkdate = getdate(strtotime(date("Y-m-1", $mktime))); // 1일의 첫번째 요일 (0:일, 1:월 ... 6:토)$first_day = get_first_day($year, $month);// 해당월의 마지막 날짜,$last_day = $end_day[$month]; if ($month - 1 < 1) { $before_ym = sprintf("%04d%02d", ($year-1), 12);} else { $before_ym = sprintf("%04d%02d", $year, ($month-1));} if ($month + 1 > 12) { $after_ym = sprintf("%04d%02d", ($year+1), 1);} else { $after_ym = sprintf("%04d%02d", $year, ($month+1));} echo "<tr>";echo "<td colspan='2' align='right'><a href='$_SERVER[PHP_SELF]?bo_table=$bo_table&schedule_ym=$before_ym'><img src='img/month_prev.gif' border='0'></a></td>";echo "<td colspan='3' align='center' class='sc_ym'>";echo " $year / $month ";echo "</td>";echo "<td colspan='2' align='left'><a href='$_SERVER[PHP_SELF]?bo_table=$bo_table&schedule_ym=$after_ym'><img src='img/month_next.gif' border='0'></a></td>";echo "</tr>"; // 요일$yoil = array ("일", "월", "화", "수", "목", "금", "토");echo "<tr>";for ($i=0; $i<7; $i++) { $width = '13%'; $class = array(); $class[] = "sc_tit"; if ($i == 0) $class[] = "sc_sun"; else if ($i == 6) { $class[] = "sc_sat"; $width = '12%'; } $class_list = implode(" ", $class); echo "<td class='$class_list' width='$width'>$yoil[$i]</td>";}echo "</tr>"; $cnt = $day = 0;for ($i=0; $i<6; $i++) { echo "<tr>"; for ($k=0; $k<7; $k++) { $cnt++; echo "<td class='sc_day'>"; if ($cnt > $first_day) { $day++; if ($day <= $last_day) { $class = array(); // 오늘이라면 if ($today[year] == $year && $today[mon] == $month && $today[mday] == $day) { $class[] = "sc_today"; } $current_ymd = $current_ym . sprintf("%02d", $day); if ($k == 0) $class[] = "sc_sun"; else if ($k == 6) $class[] = "sc_sat"; $class_list = implode(" ", $class); echo "<div class='$class_list'>"; $sql = " select wr_subject, wr_id from $g4[write_prefix]$bo_table where wr_1 = '$current_ymd' and wr_is_comment = 0 order by wr_num "; $result = sql_query($sql); $num = @mysql_num_rows($result); if ($num) { echo "<a href='$g4[bbs_path]/board.php?bo_table=$bo_table&sfl=wr_1&stx=$current_ymd');\" title='일정건수 : {$row[cnt]}건'>"; echo $day; echo "</a>"; while ($row=sql_fetch_array($result)) { echo "<div class='subject'>"; echo "<a href='$g4[bbs_path]/board.php?bo_table=$bo_table&wr_id=$row[wr_id]'>"; echo $row[wr_subject]; echo "</a>"; echo "</div>"; } } else { echo $day; } echo "</div>"; } else { echo " "; } } else { echo " "; } echo "</td>"; } echo "</tr>\n"; if ($day >= $last_day) break;}?></table>...
답변 1개
채택된 답변
+20 포인트
2016-04-01 (금) 14:32:33
// 1일의 첫번째 요일 (0:일, 1:월 ... 6:토) |
025 | $first_day = get_first_day($year, $month); |
// 요일 |
050 | $yoil = array ("일", "월", "화", "수", "목", "금", "토"); |
|
087 | $class[] = "sc_sun"; |
088 | else if ($k == 6) |
089 | $class[] = "sc_sat"; |
일단 이부분들을 바꾸셔야 할듯하네요.
바꿔가시며 충돌나는 다른부분들은 수정하시면 될것 같네요.
답변을 작성하려면 로그인이 필요합니다.