unset($_SESSION); session_destroy(); header("Location:index.php"); } else { if ($mode == 7) { $snippet(array('title' => $title, 'bland' => $bland, 'menu' => $menu)); } } } } } //表示 } else { //ディフォールトページ設定 if ($page < 0 && strlen($start) > 0) { parse_str(parse_url($start, PHP_URL_QUERY), $_GET); $page = array_getn($_GET, 'p'); } $ym = array_get($_GET, 'ym'); if (array_get($_GET, 'feed') == 'atom') { $atom(); } else { list($bland, $menu) = dbGetMenu(-1); if ($page <= 0) { $mainidx(array('title' => $blog, 'bland' => $bland, 'data' => dbGetContents(0), 'menu' => $menu, 'ym' => $ym)); //各ページ themeの切り替えはreq.php内の$themeで変更 } else { $disp(array('title' => $blog, 'bland' => $bland, 'data' => dbGetContents($page), 'menu' => $menu)); } } }
$smenu[$cnt] = array($line[0] => $line[1]); $prev =& $smenu[$cnt]; $cnt++; } } } } else { break; } } unset($prev); dbSetMenu(array('bland' => $sbland, 'menu' => $smenu)); echo "設定完了"; //編集 } else { list($sbland, $smenu) = dbGetMenu(-1); foreach ($smenu as $key => $value) { if (is_array($value)) { foreach ($value as $key2 => $value2) { $text .= " {$key2},{$value2}\n"; } } else { $text .= "{$key},{$value}\n"; } } $text .= "\n"; foreach ($_contents as $value) { if ($value['mode'] == 1) { //固定ページのみ if (strpos($text, $value['title']) === false && strpos($text, "index.php?p={$value['page']}") === false) { $text .= "{$value['title']},index.php?p={$value['page']}\n";