This commit is contained in:
唐钰豆豆 2019-08-18 22:59:36 +08:00
parent 671e4e7f68
commit 21a56df14c
7 changed files with 8 additions and 8 deletions

View file

@ -6,17 +6,17 @@ if (!defined('IN_SYS')) {
}
$section = empty($_GET["s"]) ? "uiisc" : $_GET["s"];
$enable_section = [
"crogram" => ["title" => "Crogram"],
"ifastnet" => ["title" => "iFastNet"],
"uiisc" => ["title" => "UIISC"]
];
$enable_section = array(
"crogram" => array("title" => "Crogram"),
"ifastnet" => array("title" => "iFastNet"),
"uiisc" => array("title" => "UIISC")
);
$section_page = "{$ROOT}/core/views/about_{$section}.php";
$section_page = "{$ROOT}/core/views/about/{$section}.php";
if (is_file(($section_page))) {
$title = $title . ' - ' . $lang->I18N('about') . ' ' . $enable_section[$section]['title'];
} else {
$title = $title . ' - ' . $lang->I18N('about');
$section_page = "{$ROOT}/core/views/about_uiisc.php";
$section_page = "{$ROOT}/core/views/about/uiisc.php";
}

View file

@ -8,7 +8,7 @@ if (!defined('IN_SYS')) {
$title = $title . ' - ' . $lang->I18N('news');
$news_id = filter_input(INPUT_GET, 'id', FILTER_SANITIZE_STRING);
$section_page = empty($news_id) ? "{$ROOT}/core/views/news.php" : "{$ROOT}/core/views/news_details.php";
$section_page = empty($news_id) ? "{$ROOT}/core/views/news/list.php" : "{$ROOT}/core/views/news/details.php";
if (!is_file($section_page)) {
header("HTTP/1.1 404 Not Found");