« $title »"; echo ""; //echo ""; echo ""; echo "\n"; for($x=0; $x<7; $x++){ echo ""; } echo "\n"; for($y=0; $y<6; $y++){ echo ""; for($x=0; $x<7; $x++){ $d = $y*7+$x+1-$wday;//日付け /* if($cm == $this_month && $d==$this_day){ $quote1 = "["; $quote2 = "]"; }else{ $quote1 = ""; $quote2 = ""; } */ $aim = $year.$month; $path = "../data"; $dir_name = dir($path); while($file_name = $dir_name->read()){ $files[] = $file_name; } rsort($files); foreach($files as $file){ if(strstr($file,$aim) != ""){ $list[] .= $file;//ファイル名 $days[] .= substr($file,6,2);//投稿日(二桁表記)。ファイル名より抽出... } } $d2 = sprintf("%02d",$d);//「投稿日」との比較のため、二桁表記の「日付け」も準備する。 $path = sprintf("../entry.php?path=./data/%04d%02d%02d.txt",$year,$month,$d);//permalink url if(($cm == $this_month && $d==$this_day) && (is_array($days) && in_array($d2,$days))){//「本日」かつ「投稿日」の場合 $tag1 = ""; $tag2 = ""; }elseif($cm == $this_month && $d==$this_day){//「本日」の場合 $tag1 = ""; $tag2 = ""; }elseif(is_array($days) && in_array($d2,$days)){//「投稿日」の場合 $tag1 = ""; $tag2 = ""; }else{//「本日」以外、かつ「投稿日」以外、の場合 $tag1 = ""; $tag2 = ""; } echo "\n"; } echo "\n"; } echo "
« $title »
« $title »
$wtxt[$x]
"; $param = sprintf("date=%04d%02d%02d",$cy,$cm,$d); $addr = sprintf("%s?%s",$self,$param); if($d>0 && $d<($maxd+1)){ //echo "{$quote1}{$d}{$quote2}"; echo "{$tag1}{$d}{$tag2}"; }else{echo " ";}; echo "
\n"; } function archives(){ $path = "../data"; $dir_name = dir($path); while($file_name = $dir_name->read()){ if(strstr($file_name,".txt") != ""){ $files[] = $file_name; } } rsort($files); foreach($files as $file){ $archive = substr($file,0,6); $list[] .= $archive; } $list = array_unique($list);//重複する要素を排除し、 $list = array_values($list);//連番のインデックスに再設定... echo "

archives

"; echo ""; } function recent_entries(){ $path = "../data"; $dir_name = dir($path); while($file_name = $dir_name->read()){ if(strstr($file_name,".txt") != ""){ $files[] = $file_name; } } rsort($files); foreach($files as $file){ $list[] .= $file; } echo "

recent entries

"; echo ""; } function bookmark(){ $fn = "link.txt"; $lines = file($fn); for($i=0; $i§ $link[0]

"; } } //$self = $HTTP_SERVER_VARS['PHP_SELF']; $self = "../diary.php"; if($_GET['date'] == ""){ $year = date("Y"); $month = date("m"); $date = date("d"); }else{ $year = substr($_GET['date'],0,4); $month = substr($_GET['date'],4,2); $date = substr($_GET['date'],6,2); } $link1 = sprintf("%s?date=%04d%02d%02d",$self,$year,$month-1,$date); $link2 = sprintf("%s?date=%04d%02d%02d",$self,$year,$month+1,$date); $fn = "../summary.txt"; $all = file_get_contents($fn); $parts = explode("###",$all); $mytitle = $parts[0]; $myurl = $parts[1]; $mydescription = $parts[2]; ?> <br /> <b>Notice</b>: Undefined variable: mytitle in <b>/home/users/2/ciao.jp-aprilsnow/web/test/diary/bookmark/bookmark.php</b> on line <b>184</b><br />
skip to content
skip to navigation