query($sql); write_msg('链接申请提交成功,管理员审核通过后显示', Rewrite('about', array('part' => 'friendlink'))); exit(); } $cache = get_cache_config(); require_once MYMPS_INC . '/cachepages.class.php'; if ($part == 'aboutus') { $seo = $seo ? $seo : get_seoset(); $rewrite = $seo['seo_force_category']; if ($rewrite != 'active') { $mayimobile = get_mobile_settings(); $mayimobile['mobiledomain'] = $mayimobile['mobiledomain'] ? $mayimobile['mobiledomain'] : $mymps_global['SiteUrl'] . '/m'; $mayimobile['mobileuri'] = $mayimobile['mobiledomain'] . ($_SERVER['HTTP_X_ORIGINAL_URL'] ? $_SERVER['HTTP_X_ORIGINAL_URL'] : $_SERVER['REQUEST_URI']); if ($ifmobile) { write_msg('', $mayimobile['mobileuri']); exit(); } } !$id && ($id = $db->getOne('SELECT MIN(id) FROM `' . $db_mymps . 'about`')); $cachepages = new cachepages($cache['aboutus']['time'], 'aboutus_' . $id); $cachetime = 0 < $cache['aboutus']['time'] ? true : false; $cachepages->cacheCheck(); $aboutus_all = get_aboutus(0); $aboutus = get_aboutus($id); $loc = get_location('aboutus', '', $aboutus['typename']); $page_title = $loc['page_title']; $location = $loc['location']; } else if ($part == 'announce') { $cachepages = new cachepages($cache['announce']['time'], 'announce'); $cachetime = 0 < $cache['announce']['time'] ? true : false; $cachepages->cacheCheck(); $loc = get_location('aboutus', '', '网站公告'); $query = $db->query('SELECT * FROM `' . $db_mymps . 'announce` WHERE begintime<=\'' . $timestamp . '\' AND (endtime=\'0\' OR endtime>\'' . $timestamp . '\') ORDER BY id DESC'); while ($row = $db->fetchRow($query)) { $arr['id'] = $row['id']; $arr['title'] = $row['title']; $arr['begintime'] = $row['begintime'] == 0 ? $row['pubdate'] : $row['begintime']; $arr['endtime'] = $row['endtime']; $arr['author'] = $row['author']; $arr['content'] = $row['redirecturl'] ? '' . $row[redirecturl] . '' : $row['content']; $arr['uri'] = $row['redirecturl'] ? $row['redirecturl'] : Rewrite('about', array('part' => 'aboutus#' . $row['id'])); $announce[] = $arr; } } else if ($part == 'faq') { !$id && ($id = $db->getOne('SELECT MIN(id) FROM `' . $db_mymps . 'faq`')); $cachepages = new cachepages($cache['faq']['time'], 'faq_' . $id); $cachetime = 0 < $cache['faq']['time'] ? true : false; $cachepages->cacheCheck(); $faq_type = get_faq(); if (!($faq = get_faq($id))) { write_msg('您指定的帮助主题不存在!'); } $loc = get_location('faq', '', $faq['title']); } else if ($part == 'friendlink') { require MYMPS_INC . '/flink.fun.php'; $cachepages = new cachepages($cache['friendlink']['time'], 'friendlink'); $cachetime = 0 < $cache['friendlink']['time'] ? true : false; $cachepages->cacheCheck(); $loc = get_location('friendlink', '', '友情链接'); $flink = get_flink(); } else if ($part == 'sitemap') { $loc = get_location('', '', '网站地图'); $cachepages = new cachepages($cache['sitemap']['time'], 'sitemap'); $cachetime = 0 < $cache['sitemap']['time'] ? true : false; $cachepages->cacheCheck(); $categories = get_categories_tree(0, 'category'); } $page_title = $loc['page_title']; $location = $loc['location']; $about = array(); $about['aboutus_uri'] = Rewrite('about', array('part' => 'aboutus')); $about['news_uri'] = Rewrite('news', array('part' => 'index')); $about['faq_uri'] = Rewrite('about', array('part' => 'faq')); $about['yp_uri'] = Rewrite('corp', array('part' => 'index')); $about['friendlink_uri'] = Rewrite('about', array('part' => 'friendlink')); $about['announce_uri'] = Rewrite('about', array('part' => 'announce')); $about['sitemap_uri'] = Rewrite('about', array('part' => 'sitemap')); include mymps_tpl($part); $cachetime && $cachepages->caching(); is_object($db) && $db->Close(); ?>