コード例 #1
0
 * 后台管理栏目Google Sitemaps文件
 *
 * @author		Arthur(ArthurXF@gmail.com)
 * @copyright	(c) 2006 by bizeway.com
 * @version		$Id$
 * @package		ArthurXF
 * @subpackage	admin
 */
require_once '../config/config.inc.php';
require_once '../checklogin.php';
require_once 'class/google_sitemap.class.php';
$objWebInit = new google_sitemap();
//smarty参数
$objWebInit->arrGSmarty = $arrGSmarty;
//数据库连接参数
$objWebInit->setDBG($arrGPdoDB);
$objWebInit->db();
//访问权限检查
if (!$objWebInit->checkPopedomG($_SESSION['user_id'], 'seo')) {
    check::AlertExit('对不起,您没有权限访问此页', -1);
}
if ($_SERVER["REQUEST_METHOD"] == "POST") {
    $sm_file = '../../sitemap.xml';
    if (is_writable($sm_file)) {
        @set_time_limit(0);
        //$domain = $arrGWeb['host'];
        $domain = $_SERVER['HTTP_HOST'];
        if ($_POST['today']) {
            $today = date('c');
        } else {
            $today = '';