• R/O
  • HTTP
  • SSH
  • HTTPS

Commit

Tags
No Tags

Frequently used words (click to add to your profile)

javac++androidlinuxc#windowsobjective-ccocoa誰得qtpythonphprubygameguibathyscaphec計画中(planning stage)翻訳omegatframeworktwitterdomtestvb.netdirectxゲームエンジンbtronarduinopreviewer

カレンダ機能を追加する


Commit MetaInfo

Revisiond43334288f8a1033f5b4e57899f5809c5d2654f3 (tree)
Time2017-06-11 15:42:17
Authorstingll <jostingll@gmai...>
Commiterstingll

Log Message

表示対象月を今日日付の一ヶ月前から、5ヶ月先まで表示するように変更
配列要素(インシデントはUnixTime)で、URLリストを事前に作成して対象
日付に表示するように変更。
これで後は作業項目の検討開始日程の「詳細とID」のHrefと、工事開始日時
のhref配列を作成すればよい。

Change Summary

Incremental Difference

--- a/PHP/cnstplando.php
+++ b/PHP/cnstplando.php
@@ -14,7 +14,18 @@ print "<body>\n";
1414
1515 // 今年の西暦をデフォルトとして表示するために事前設定
1616 $nen = date("Y");
17-$gen = date("m");
17+// 表示する日付の制御変数の設定
18+$nenxt = $nen + 1; // 6ヶ月後が年を超える場合の対処
19+$nenpr = $nen -1; // その月が1月の場合、年号を前年にするための変数
20+$gen = date("m"); // 今日の日の月を求める
21+$genxt = $gen + 6; // 表示するための変数、デフォルト今日日付の前の月から6ヶ月後まで表示するための変数
22+if ( $gen == 1 ) { // 1月だったら変数設定を変える、1月の前月が0月となるため、年と月を修正する
23+ $genpr = 12;
24+ $nen = $nenpr;
25+} else {
26+ $genpr = $gen - 1;
27+}
28+
1829
1930 ?>
2031
@@ -120,9 +131,9 @@ echo '<br />';
120131 echo '<table class="width100" border="1" cellspacing="1">';
121132 echo '<tr class="row-category">';
122133 echo ' <th>日(曜)</th>';
123-echo ' <th>和祭日</th>';
124-echo ' <th>お客様工事要望</th>';
125-echo ' <th>時間</th>';
134+echo ' <th>祭日名</th>';
135+echo ' <th>検討開始期間</th>';
136+echo ' <th>時刻</th>';
126137 echo ' <th>SC-RP工事計画日</th>';
127138 echo ' <th>SC-RP工事実行日</th>';
128139 echo '</tr>';
@@ -158,14 +169,46 @@ echo '</tr>';
158169
159170
160171 <?php
172+$peri = 25; // 1時間刻みの場合、「25」。30分刻みなら「50」、15分刻みなら「100」
173+$lordwar = "<td align='center' rowspan='25'>"; //平日の無色設定
174+$lordrow = "<td rowspan='25'>"; //平日の無色設定
175+$lcolorPk = "<td align='center' bgcolor='#ffc0cb' rowspan='25'>"; //背景を pink に with align(location) and rowspan, peri=25
176+$coulorPk = "<td bgcolor='#ffc0cb' rowspan='25'>"; //背景を pink に with rowspan
177+$lcolorDg = "<td align='center' bgcolor='#8fbc8f' rowspan='25'>"; //背景を darkseagreen に
178+$coulorDg = "<td bgcolor='#8fbc8f' rowspan='25'>"; //背景を darkseagreen に
179+$lcolorLb = "<td align='center' bgcolor='#b0c4de' rowspan='25'>"; //背景を lightsteelblue に
180+$coulorLb = "<td bgcolor='#b0c4de' rowspan='25'>"; //背景を lightsteelblue に
181+
182+// 今年の西暦をデフォルトとして表示するために事前設定
183+$nen = date("Y");
184+// 表示する日付の制御変数の設定
185+$nenxt = $nen + 1; // 6ヶ月後が年を超える場合の対処
186+$nenpr = $nen -1; // その月が1月の場合、年号を前年にするための変数
187+$gen = date("m"); // 今日の月を求める
188+$genxt = $gen + 6; // 表示するための変数、デフォルト今日日付の前の月から6ヶ月後まで表示するための変数
189+if ( $gen == 1 ) { // 1月だったら変数設定を変える、1月の前月が0月となるため、年と月を修正する
190+ $genpr = 12;
191+ $nen = $nenpr;
192+} else {
193+ $genpr = $gen - 1;
194+}
195+
161196 $youbi = array("日","月","火","水","木","金","土"); //曜日を配列に入れる
162197 $tdiv = 0; //テーブルの数を数えるための変数
163-for ($gatsu = 1; $gatsu <= 12; $gatsu++) { //月に1を足しながら12月まで繰り返し
198+
199+//for ($gatsu = 1; $gatsu <= 12; $gatsu++) { //月に1を足しながら12月まで繰り返し
200+for ($gatsu = $genpr ; $gatsu < $genxt; $gatsu++) { //今日の月より前月より6ヶ月後まで表示
164201
165202 // 1日の曜日を取得して月始まりを判断する
166203 $hi = 1; //"日"は 1 から始める
204+ if ( $gatsu > 12 ) {
205+ $you = date("w", mktime(0, 0, 0, $gatsu-12, $hi, $nenxt)); //1日の曜日
206+ } else {
207+ $you = date("w", mktime(0, 0, 0, $gatsu, $hi, $nen)); //1日の曜日
208+ }
167209 $you = date("w", mktime(0, 0, 0, $gatsu, $hi, $nen)); //1日の曜日
168210
211+
169212 // echo '<table class="width100" border="1" cellspacing="1">';
170213 echo '<tr class="row-category">';
171214 // echo ' <th>月日(曜日)</th>';
@@ -180,7 +223,7 @@ for ($gatsu = 1; $gatsu <= 12; $gatsu++) { //月に1を
180223
181224 print "<tr><br></tr>\n"; //行変えする
182225 print "</table><br><td>\n";
183- print $nen . "年" . $gatsu . "月</td>\n";
226+ print "<H1>" . $nen . "年" . $gatsu . "月</td></H1>\n";
184227 print "<table class=\"width100\" border=\"1\" cellspacing=\"1\">";
185228 // echo '</tr>\n';
186229 // echo '<tr>\n';
@@ -200,8 +243,12 @@ for ($gatsu = 1; $gatsu <= 12; $gatsu++) { //月に1を
200243 // }
201244 // }
202245 $monday = 0; //初期値を 0 として変数 $you を設定
203- for ($i = $hi; $i < 32; $i++) { //日付に1を足しながら40日まで繰り返し
246+ for ($i = $hi; $i < 32; $i++) { //日付に1を足しながら32日まで繰り返し
204247 $you = date("w", mktime(0, 0, 0, $gatsu, $hi, $nen)); //曜日
248+
249+ $pidnt = date("U", mktime(0, 0, 0, $gatsu, $hi, $nen)); //Unix time 取得 配列のサフィックス利用
250+// print "<H1>" . $pidnt . "</H1>\n";
251+
205252 if ($you == 1) { //月曜日なら$mondayに+1
206253 $monday++;
207254 }
@@ -211,95 +258,96 @@ for ($gatsu = 1; $gatsu <= 12; $gatsu++) { //月に1を
211258 $syuubun = (int)(23.09000 + 0.2421904 * $y2 - (int)($y2/4 + $y2/100 + $y2/400));
212259
213260 if (($nen == date("Y")) && ($gatsu == date("n")) && ($hi == date("d"))) { //今日なら
214- print "<td align='center' bgcolor='#8fbc8f' rowspan='25'>" . $hi . "(" . $youbi[$you] . ")</td><td bgcolor='#8fbc8f' rowspan='25'>本日</td>\n"; //背景を darkseagreen に
261+ print $lcolorDg . $hi . "(" . $youbi[$you] . ")</td>" . $coulorDg . "本日</td>" . $lcolorDg . $contstpl[$pidnt] ."</td>\n"; //背景を darkseagreen に
215262 } elseif (($gatsu == 1) && ($hi == 1)) { //元日(1月1日なら)
216- print "<td align='center' bgcolor='#ffc0cb' rowspan='25'>" . $hi . "(" . $youbi[$you] . ")</td><td bgcolor='#ffc0cb' rowspan='25'>元旦</td>\n"; //背景を pink に
263+ print $lcolorPk . $hi . "(" . $youbi[$you] . ")</td>" . $coulorPk . "元旦</td>" . $lcolorPk . $contstpl[$pidnt] . "</td>\n"; //背景を pink に
217264 } elseif (($gatsu == 1) && ($hi == 2)) { //元日の振替休日(1月2日が月曜なら)
218- print "<td align='center' bgcolor='#ffc0cb' rowspan='25'>" . $hi . '(' . $youbi[$you] . ")</td><td bgcolor='#ffc0cb' rowspan='25'>三箇日</td>\n"; //背景を pink に
265+ print $lcolorPk . $hi . '(' . $youbi[$you] . ")</td>" . $coulorPk . "三箇日</td>" . $lcolorPk . $contstpl[$pidnt] . "</td>\n"; //背景を pink に
219266 } elseif (($gatsu == 1) && ($hi == 3)) { //1月3日まで三箇日として休み設定
220- print "<td align='center' bgcolor='#ffc0cb' rowspan='25'>" . $hi . '(' . $youbi[$you] . ")</td><td bgcolor='#ffc0cb' rowspan='25'>三箇日</td>\n"; //背景を pink に
267+ print $lcolorPk . $hi . '(' . $youbi[$you] . ")</td>" . $coulorPk . "三箇日</td>" . $lcolorPk . $contstpl[$pidnt] . "</td>\n"; //背景を pink に
221268 } elseif (($gatsu == 1) && ($monday == 2) && ($you == 1)) { //成人の日(1月の第2月曜なら)
222- print "<td align='center' bgcolor='#ffc0cb' rowspan='25'>" . $hi . "(" . $youbi[$you] . ")</td><td bgcolor='#ffc0cb' rowspan='25'>成人</td>\n"; //背景を pink に
269+ print $lcolorPk . $hi . "(" . $youbi[$you] . ")</td>" . $coulorPk . "成人</td>" . $lcolorPk . $contstpl[$pidnt] . "</td>\n"; //背景を pink に
223270 } elseif (($gatsu == 2) && ($hi == 11)) { //建国記念の日(2月11日なら)
224- print "<td align='center' bgcolor='#ffc0cb' rowspan='25'>" . $hi . "(" . $youbi[$you] . ")</td><td bgcolor='#ffc0cb' rowspan='25'>建国</td>\n"; //背景を pink に
271+ print $lcolorPk . $hi . "(" . $youbi[$you] . ")</td>" . $coulorPk . "建国</td>" .$lcolorPk . $contstpl[$pidnt] . "</td>\n"; //背景を pink に
225272 } elseif (($gatsu == 2) && ($hi == 12) && ($you == 1)) { //建国記念の日の振替休日(2月12日が月曜なら)
226- print "<td align='center' bgcolor='#ffc0cb' rowspan='25'>" . $hi . "(" . $youbi[$you] . ")</td>建国振替<td rowspan='25'></td>\n"; //背景を pink に
273+ print $lcolorPk . $hi . "(" . $youbi[$you] . ")</td>". $coulorPk . "建国振替</td>" .$lcolorPk . $contstpl[$pidnt] . "</td>\n"; //背景を pink に
227274 } elseif (($nen > 1999 ) && ($gatsu == 3) && ($hi == $syunbun)) { //春分の日(計算式による)
228- print "<td align='center' bgcolor='#ffc0cb' rowspan='25'>" . $hi . "(" . $youbi[$you] . ")</td><td bgcolor='#ffc0cb' rowspan='25'>春分</td><td rowspan='25'></td>\n"; //背景を pink に
275+ print $lcolorPk . $hi . "(" . $youbi[$you] . ")</td>" . $coulorPk . "春分</td>" .$lcolorPk . $contstpl[$pidnt] . "</td>\n"; //背景を pink に
229276 } elseif (($nen > 1999 ) && ($gatsu == 3) && ($hi == ($syunbun + 1)) && ($you == 1)) { //春分の日の振替休日
230- print "<td align='center' bgcolor='#ffc0cb' rowspan='25'>" . $hi . "(" . $youbi[$you] . ")</td>春分振替<td rowspan='25'></td>\n"; //背景を pink に
277+ print $lcolorPk . $hi . "(" . $youbi[$you] . ")</td>" . $coulorPk . "春分振替</td>" .$lcolorPk . $contstpl[$pidnt] . "</td>\n"; //背景を pink に
231278 } elseif (($nen < 2007) && ($gatsu == 4) && ($hi == 29)) { //2006年みどりの日(4月29日なら)
232- print "<td align='center' bgcolor='#ffc0cb' rowspan='25'>" . $hi . "(" . $youbi[$you] . ")</td><td bgcolor='#ffc0cb' rowspan='25'>緑日</td>\n"; //背景を pink に
279+ print $lcolorPk . $hi . "(" . $youbi[$you] . ")</td>" . $coulorPk . "緑日</td>" .$lcolorPk . $contstpl[$pidnt] . "</td>\n"; //背景を pink に
233280 } elseif (($nen < 2007) && ($gatsu == 4) && ($hi == 30) && ($you == 1)) { //みどりの日の振替休日(4月30日が月曜なら)
234- print "<td align='center' bgcolor='#ffc0cb' rowspan='25'>" . $hi . "(" . $youbi[$you] . ")</td>\n"; //背景を pink に
281+ print $lcolorPk . $hi . "(" . $youbi[$you] . ")</td>" . $coulorPk . "緑日振替</td>" . $lcolorPk . $conststpl[$pidnt] . "</td>\n"; //背景を pink に
235282 } elseif (($nen > 2006) && ($gatsu == 4) && ($hi == 29)) { //昭和の日(4月29日なら)
236- print "<td align='center' bgcolor='#ffc0cb' rowspan='25'>" . $hi . "(" . $youbi[$you] . ")</td><td bgcolor='#ffc0cb' rowspan='25'>昭和</td>\n"; //背景を pink に
283+ print $lcolorPk . $hi . "(" . $youbi[$you] . ")</td>" . $coulorPk . "昭和</td>" .$lcolorPk . $contstpl[$pidnt] . "</td>\n"; //背景を pink に
237284 } elseif (($nen > 2006) && ($gatsu == 4) && ($hi == 30) && ($you == 1)) { //昭和の日の振替休日(4月30日が月曜なら)
238- print "<td align='center' bgcolor='#ffc0cb' rowspan='25'>" . $hi . "(" . $youbi[$you] . ")</td>昭和振替<td rowspan='25'></td>\n"; //背景を pink に
285+ print $lcolorPk . $hi . "(" . $youbi[$you] . ")</td>" . $coulorPk . $peri . "'>昭和振替</td>" .$lcolorPk . $contstpl[$pidnt] . "</td>\n"; //背景を pink に
239286 } elseif (($gatsu == 5) && ($hi == 3)) { //憲法記念日(5月3日なら)
240287 if (($nen > 2006) && ($you == 0)) { //憲法記念日が日曜なら
241288 $kokuminf = on; //振替休日有りの印を付ける
242289 }
243- print "<td align='center' bgcolor='#ffc0cb' rowspan='25'>" . $hi . "(" . $youbi[$you] . ")</td><td bgcolor='#ffc0cb' rowspan='25'>憲法</td>\n"; //背景を pink に
290+ print $lcolorPk . $hi . "(" . $youbi[$you] . ")</td>" . $coulorPk . "憲法</td>" .$lcolorPk . $contstpl[$pidnt] . "</td>\n"; //背景を pink に
244291 } elseif ((($nen < 2007) && ($gatsu == 5) && ($hi == 4) && ($you == 2)) or (($nen < 2007) && ($gatsu == 5) && ($hi == 4) && ($you == 3)) or (($nen < 2007) && ($gatsu == 5) && ($hi == 4) && ($you == 4)) or (($nen < 2007) && ($gatsu == 5) && ($hi == 4) && ($you == 5)) or (($nen < 2007) && ($gatsu == 5) && ($hi == 4) && ($you == 6))) {
245- print "<td align='center' bgcolor='#ffc0cb' rowspan='25'>" . $hi . "(" . $youbi[$you] . ")</td><td bgcolor='#ffc0cb' rowspan='25'>憲法振替</td>\n"; //背景を pink に
292+ print $lcolorPk . $hi . "(" . $youbi[$you] . ")</td>" . $coulorPk . $peri . "'>憲法振替</td>" .$lcolorPk . $contstpl[$pidnt] . "</td>\n"; //背景を pink に
246293 } elseif (($nen > 2006) && ($gatsu == 5) && ($hi == 4)) { //2007年以降みどりの日(5月4日なら)
247294 if (($nen > 2006) && ($kokuminf != on) && ($you == 0)) { //みどりの日が日曜なら
248295 $kokuminf = on; //振替休日有りの印を付ける
249296 }
250- print "<td align='center' bgcolor='#ffc0cb' rowspan='25'>" . $hi . "(" . $youbi[$you] . ")</td><td bgcolor='#ffc0cb' rowspan='25'>緑日</td>\n"; //背景を pink に
297+ print $lcolorPk . $hi . "(" . $youbi[$you] . ")</td>" . $coulorPk . "緑日</td>" .$lcolorPk . $contstpl[$pidnt] . "</td>\n"; //背景を pink に
251298 } elseif (($gatsu == 5) && ($hi == 5)) { //こどもの日(5月5日なら)
252299 if (($nen > 2006) && ($kokuminf != on) && ($you == 0)) { //こどもの日が日曜なら
253300 $kokuminf = on; //振替休日有りの印を付ける
254301 }
255- print "<td align='center' bgcolor='#ffc0cb' rowspan='25'>" . $hi . "(" . $youbi[$you] . ")</td><td bgcolor='#ffc0cb' rowspan='25'>子供</td>\n"; //背景を pink に
302+ print $lcolorPk . $hi . "(" . $youbi[$you] . ")</td>" . $coulorPk . "子供振替</td>" .$lcolorPk . $contstpl[$pidnt] . "</td>\n"; //背景を pink に
256303 } elseif (($nen < 2007) && ($gatsu == 5) && ($hi == 6) && ($you == 1)) { //こどもの日の振替休日(5月6日が月曜なら)
257- print "<td align='center' bgcolor='#ffc0cb' rowspan='25'>" . $hi . "(" . $youbi[$you] . ")</td><td bgcolor='#ffc0cb' rowspan='25'>子供振替</td>\n";//背景を pink に
304+ print $lcolorPk . $hi . "(" . $youbi[$you] . ")</td>" . $coulorPk . "子供振替</td>" .$lcolorPk . $contstpl[$pidnt] . "</td>\n";//背景を pink に
258305 } elseif (($nen > 2006) && ($kokuminf == on) && ($gatsu == 5) && ($hi == 6)) { //3連祝日のどれかが日曜なら振替休日
259- print "<td align='center' bgcolor='#ffc0cb' rowspan='25'>" . $hi . "(" . $youbi[$you] . ")</td><td bgcolor='#ffc0cb' rowspan='25'>国民振替</td>\n";//背景を pink に
306+ print $lcolorPk . $hi . "(" . $youbi[$you] . ")</td>" . $coulorPk . "'>国民振替</td>" . $lcolorPk . $contstpl[$pidnt] . "</td>\n";//背景を pink に
260307 } elseif (($gatsu == 7) && ($monday == 3) && ($you == 1)) { //海の日(7月の第3月曜なら)
261- print "<td align='center' bgcolor='#ffc0cb' rowspan='25'>" . $hi . "(" . $youbi[$you] . ")</td><td bgcolor='#ffc0cb' rowspan='25'>海日</td>\n"; //背景を pink に
308+ print $lcolorPk . $hi . "(" . $youbi[$you] . ")</td>" . $coulorPk . "海日</td>" .$lcolorPk . $contstpl[$pidnt] . "</td>\n"; //背景を pink に
262309 } elseif (($nen > 2015) && ($gatsu == 8) && ($hi == 11)) { //2016年以降、山の日(8月11日)なら
263- print "<td align='center' bgcolor='#ffc0cb' rowspan='25'>" . $hi . "(" . $youbi[$you] . ")</td><td bgcolor='#ffc0cb' rowspan='25'>山日</td>\n"; //背景を pink に
310+ print $lcolorPk . $hi . "(" . $youbi[$you] . ")</td>" . $coulorPk . "山日</td>" .$lcolorPk . $contstpl[$pidnt] . "</td>\n"; //背景を pink に
264311 } elseif (($nen > 2015) && ($gatsu == 8) && ($hi == 12) && ($you == 1)) { //山の日の振替休日(8月12日が月曜なら)
265- print "<td align='center' bgcolor='#ffc0cb' rowspan='25'>" . $hi . "(" . $youbi[$you] . ")</td>振替<td rowspan='25'></td>\n"; //背景を pink に
312+ print $lcolorPk . $hi . "(" . $youbi[$you] . ")</td>" . $coulorPk . "振替</td>" .$lcolorPk . $contstpl[$pidnt] . "</td>\n"; //背景を pink に
266313 } elseif (($gatsu == 9) && ($monday == 3) && ($you == 1)) { //敬老の日(9月の第3月曜なら)
267314 $keiro = $hi; //敬老の日の日付(国民の祝日の有無確認のため)
268315 if (($syuubun - $keiro) == 2) { //敬老の日の2日後が秋分の日なら
269316 $kokumin = $syuubun - 1;
270317 }
271- print "<td align='center' bgcolor='#ffc0cb' rowspan='25'>" . $hi . "(" . $youbi[$you] . ")</td><td bgcolor='#ffc0cb' rowspan='25'>敬老</td>\n"; //背景を pink に
318+ print $lcolorPk . $hi . "(" . $youbi[$you] . ")</td>" . $coulorPk . ">敬老</td>" .$lcolorPk . $contstpl[$pidnt] . "</td>\n"; //背景を pink に
272319 } elseif (($kokumin) && (($gatsu == 9) && ($hi == $kokumin))) { //9月の国民の休日が有りなら
273- print "<td align='center' bgcolor='#ffc0cb' rowspan='25'>" . $hi . "(" . $youbi[$you] . ")</td>敬老振替<td rowspan='25'></td>\n"; //背景を pink に
320+ print $lcolorPk . $hi . "(" . $youbi[$you] . ")</td>敬老振替<td rowspan='25'>" . "'</td>" .$lcolorPk . $contstpl[$pidnt] . "</td>\n"; //背景を pink に
274321 } elseif (($nen > 1999 ) && ($gatsu == 9) && ($hi == $syuubun)) { //秋分の日(計算式による)
275- print "<td align='center' bgcolor='#ffc0cb' rowspan='25'>" . $hi . "(" . $youbi[$you] . ")</td><td bgcolor='#ffc0cb' rowspan='25'>秋分</td>\n"; //背景を pink に
322+ print $lcolorPk . $hi . "(" . $youbi[$you] . ")</td>" . $coulorPk . "秋分</td>" .$lcolorPk . $contstpl[$pidnt] . "</td>\n"; //背景を pink に
276323 } elseif (($nen > 1999 ) && ($gatsu == 9) && ($hi == ($syuubun + 1)) && ($you == 1)) { //秋分の日の振替休日
277- print "<td align='center' bgcolor='#ffc0cb' rowspan='25'>" . $hi . "(" . $youbi[$you] . ")</td>秋分振替<td rowspan='25'></td>\n"; //背景を pink に
324+ print $lcolorPk . $hi . "(" . $youbi[$you] . ")</td>" . $coulorPk . "'秋分振替</td>" .$lcolorPk . $contstpl[$pidnt] . "</td>\n"; //背景を pink に
278325 } elseif (($gatsu == 10) && ($monday == 2) && ($you == 1)) { //体育の日(10月の第2月曜なら)
279- print "<td align='center' bgcolor='#ffc0cb' rowspan='25'>" . $hi . "(" . $youbi[$you] . ")</td><td bgcolor='#ffc0cb' rowspan='25'>体育</td>\n"; //背景を pink に
326+ print $lcolorPk . $hi . "(" . $youbi[$you] . ")</td>" . $coulorPk . "体育</td>" .$lcolorPk . $contstpl[$pidnt] . "</td>\n"; //背景を pink に
280327 } elseif (($gatsu == 11) && ($hi == 3)) { //文化の日(11月3日なら)
281- print "<td align='center' bgcolor='#ffc0cb' rowspan='25'>" . $hi . "(" . $youbi[$you] . ")</td><td bgcolor='#ffc0cb' rowspan='25'>文化</td>\n"; //背景を pink に
328+ print $lcolorPk . $hi . "(" . $youbi[$you] . ")</td>" . $coulorPk . "文化</td>" .$lcolorPk . $contstpl[$pidnt] . "</td>\n"; //背景を pink に
282329 } elseif (($gatsu == 11) && ($hi == 4) && ($you == 1)) { //文化の日の振替休日(11月4日が月曜なら)
283- print "<td align='center' bgcolor='#ffc0cb' rowspan='25'>" . $hi . "(" . $youbi[$you] . ")</td>文化振替<td rowspan='25'></td>\n"; //背景を pink に
330+ print $lcolorPk . $hi . "(" . $youbi[$you] . ")</td>" . $coulorPk . "文化振替</td>" .$lcolorPk . $contstpl[$pidnt] . "</td>\n"; //背景を pink に
284331 } elseif (($gatsu == 11) && ($hi == 23)) { //勤労感謝の日(11月23日なら)
285- print "<td align='center' bgcolor='#ffc0cb' rowspan='25'>" . $hi . "(" . $youbi[$you] . ")</td><td bgcolor='#ffc0cb' rowspan='25'>勤労</td>\n"; //背景を pink に
332+ print $lcolorPk . $hi . "(" . $youbi[$you] . ")</td>" . $coulorPk . "勤労</td>" . $lcolorPk . $contstpl[$pidnt] . "</td>\n"; //背景を pink に
286333 } elseif (($gatsu == 11) && ($hi == 24) && ($you == 1)) { //勤労感謝の日の振替休日(11月24日が月曜なら)
287- print "<td align='center' bgcolor='#ffc0cb' rowspan='25'>" . $hi . "(" . $youbi[$you] . ")</td>\n"; //背景を pink に
334+ print $lcolorPk . $hi . "(" . $youbi[$you] . ")</td>" . $coulorPk . "勤労振替</td> \n"; //背景を pink に
288335 } elseif (($gatsu == 12) && ($hi == 23)) { //天皇誕生日(12月23日なら)
289- print "<td align='center' bgcolor='#ffc0cb' rowspan='25'>" . $hi . "(" . $youbi[$you] . ")</td><td bgcolor='#ffc0cb' rowspan='25'>天皇</td>\n"; //背景を pink に
336+ print $lcolorPk . $hi . "(" . $youbi[$you] . ")</td>" . $coulorPk . "天皇</td>" .$lcolorPk . $contstpl[$pidnt] . "</td>\n"; //背景を pink に
290337 } elseif (($gatsu == 12) && ($hi == 24) && ($you == 1)) { //天皇誕生日の振替休日(12月24日が月曜なら)
291- print "<td align='center' bgcolor='#ffc0cb' rowspan='25'>" . $hi . "(" . $youbi[$you] . ")</td>\n"; //背景を pink に
338+ print $lcolorPk . $hi . "(" . $youbi[$you] . ")</td>" . $coulorPk . "天皇振替</td>" . $lcolorPk . $contstpl[$pidnt] . ")</td>\n"; //背景を pink に
292339 } elseif ($you == 0) { //日曜日なら
293- print "<td align='center' bgcolor='#ffc0cb' rowspan='25'>" . $hi . "(" . $youbi[$you] . ")</td><td bgcolor='#ffc0cb' rowspan='25'></td>\n"; //背景を pink に
340+ print $lcolorPk . $hi . "(" . $youbi[$you] . ")</td>" . $coulorPk . "</td>" . $lcolorPk . $contstpl[$pidnt] . "</td>\n"; //背景を pink に
294341 } elseif ($you == 6) { //土曜日なら
295- print "<td align='center' bgcolor='#b0c4de' rowspan='25'>" . $hi . "(" . $youbi[$you] . ")</td><td bgcolor='#b0c4de' rowspan='25'></td>\n"; //背景を lightsteelblue に
342+ print $lcolorLb . $hi . "(" . $youbi[$you] . ")</td>" . $lcolorLb . "</td>" . $lcolorLb . $contstpl[$pidnt] . "</td>\n";//背景を lightsteelblue に
296343 } else {
297- print "<td align='center' rowspan='25'>" . $hi . "(" . $youbi[$you] . ")</td><td rowspan='25'></td>\n"; //平日表示
344+ print $lordwar . $hi . "(" . $youbi[$you] . ")</td>" . $lordrow . "</td>" . $lordrow . $contstpl[$pidnt] . "</td>\n"; //平日表示
298345 }
299346 // stingll adding
300347 for ($j = 0; $j <= 23; $j++) {
348+ $hidnt = date("U", mktime($j, 0, 0, $gatsu, $hi, $nen)); //Unix time 取得 配列のサフィックス利用
301349 // print "<tr><td>" . printf("%'.02d\n",$j) . ":00" . "</td><td>" . "ここにIDが入る予定" . "</td></tr>\n"; //24時間の表示
302- print "<tr><td>" . $j . ":00" . "</td><td>" . "ここにIDが入る予定" . "</td></tr>\n"; //24時間の表示
350+ print "<tr align='right'><td>" . $j . ":00" . "</td><td>" . "ここにIDが入る予定" . "</td></tr>\n"; //24時間の表示
303351 }
304352
305353 $hi++;