| @@ 934-955 (lines=22) @@ | ||
| 931 | ||
| 932 | // ����̾�롼�� |
|
| 933 | $rows = array(); |
|
| 934 | for ($wday = $this->week_start; $wday < $wday_end; ++$wday) { |
|
| 935 | if ($wday % 7 == 0) { |
|
| 936 | // Sunday |
|
| 937 | $bgcolor = $this->sunday_bgcolor; |
|
| 938 | $color = $this->sunday_color; |
|
| 939 | } elseif ($wday == 6) { |
|
| 940 | // Saturday |
|
| 941 | $bgcolor = $this->saturday_bgcolor; |
|
| 942 | $color = $this->saturday_color; |
|
| 943 | } else { |
|
| 944 | // Weekday |
|
| 945 | $bgcolor = $this->weekday_bgcolor; |
|
| 946 | $color = $this->weekday_color; |
|
| 947 | } |
|
| 948 | ||
| 949 | // �ƥ�ץ졼��������ؤΥǡ������å� |
|
| 950 | array_push($rows, array( |
|
| 951 | 'BGCOLOR' => $bgcolor, |
|
| 952 | 'COLOR' => $color, |
|
| 953 | 'DAYNAME' => $this->week_short_names[$wday % 7] |
|
| 954 | )); |
|
| 955 | } |
|
| 956 | ||
| 957 | // �ƥ�ץ졼�Ȥ˥ǡ����������� |
|
| 958 | $tmpl->addRows('DayNameLoop', $rows); |
|
| @@ 1117-1138 (lines=22) @@ | ||
| 1114 | ||
| 1115 | // Loop of weeknames |
|
| 1116 | $daynames = array(); |
|
| 1117 | for ($wday = $this->week_start; $wday < $wday_end; ++$wday) { |
|
| 1118 | if ($wday % 7 == 0) { |
|
| 1119 | // Sunday |
|
| 1120 | $bgcolor = $this->sunday_bgcolor; |
|
| 1121 | $color = $this->sunday_color; |
|
| 1122 | } elseif ($wday == 6) { |
|
| 1123 | // Saturday |
|
| 1124 | $bgcolor = $this->saturday_bgcolor; |
|
| 1125 | $color = $this->saturday_color; |
|
| 1126 | } else { |
|
| 1127 | // Weekday |
|
| 1128 | $bgcolor = $this->weekday_bgcolor; |
|
| 1129 | $color = $this->weekday_color; |
|
| 1130 | } |
|
| 1131 | ||
| 1132 | // assigning weeknames |
|
| 1133 | $daynames[] = array( |
|
| 1134 | 'bgcolor' => $bgcolor, |
|
| 1135 | 'color' => $color, |
|
| 1136 | 'dayname' => $this->week_short_names[$wday % 7] |
|
| 1137 | ); |
|
| 1138 | } |
|
| 1139 | $block['daynames'] = $daynames; |
|
| 1140 | ||
| 1141 | // get the result of plugins |
|