📄 global.php
字号:
<?
/*=====================================================
Copyright (C) ETERNAL<cqz78@qq.com>
Modify : 2005/01/01
URL : http://zqkls.uu1001.com/thread.php?fid=49
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
===================================================== */
// ###################### Start init #######################
// gzip start
$do_gzip_compress = FALSE;
if ($wog_arry["gzip_compress"])
{
$phpver = phpversion();
$useragent = (isset($_SERVER["HTTP_USER_AGENT"]) ) ? $_SERVER["HTTP_USER_AGENT"] : $HTTP_USER_AGENT;
if ( $phpver >= '4.0.4pl1' && ( strstr($useragent,'compatible') || strstr($useragent,'Gecko') ) )
{
if ( extension_loaded('zlib') )
{
ob_start('ob_gzhandler');
}
}
else if ( $phpver > '4.0' )
{
if ( strstr($HTTP_SERVER_VARS['HTTP_ACCEPT_ENCODING'], 'gzip') )
{
if ( extension_loaded('zlib') )
{
$do_gzip_compress = TRUE;
ob_start();
ob_implicit_flush(0);
header('Content-Encoding: gzip');
}
}
}
}
post_check($_POST);
unset($dbservertype);
//load config
require('./forum_support/config/config.php');
// init db **********************
// load db class
$dbservertype = strtolower($dbservertype);
$dbclassname="./forum_support/config/db_$dbservertype.php";
require($dbclassname);
$DB_site=new DB_Sql_vb;
$DB_site->appname='WOG';
$DB_site->appshortname='WOG';
$DB_site->database=$dbname;
$DB_site->connect($servername, $dbusername, $dbpassword, $usepconnect);
//$DB_site->query_first("SET NAMES gb2312;");
//$DB_site->query_first("SET CHARACTER_SET_CLIENT=gb2312;");
//$DB_site->query_first("SET CHARACTER_SET_RESULTS=gb2312;");
unset($servername, $dbusername, $dbpassword, $usepconnect);
//$DB_site->connect();
$dbpassword="";
$DB_site->password="";
// end init db
// ###################### Start functions #######################
?>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -