<?php $TB_pre = $webdb[passport_pre] ? $webdb[passport_pre] : "cdb_"; $TB_path = $webdb[passport_path]; $TB_url = $webdb[passport_url]; $_DCACHE[settings][attachurl] = 'attachments'; //论坛附件目录 $TB[table] = "{$TB_pre}members"; $TB[uid] = "uid"; $TB[username] = "username"; $TB[password] = "password"; @(include ROOT_PATH . 'data/uc_config.php'); @(include ROOT_PATH . 'do/uc_client/client.php'); if (UC_DBHOST != $dbhost || UC_DBUSER != $dbuser || UC_DBPW != $dbpw) { $db_uc = new MYSQL_DB(); $db_uc->connect(UC_DBHOST, UC_DBUSER, UC_DBPW, UC_DBNAME, $pconnect = '', 1); } else { $db_uc =& $db; } /** *取得用户数据 **/ function PassportUserdb() { global $userDB; $detail = $userDB->login_info(); return $detail; }
require_once ROOT_PATH . 'data/level.php'; $timestamp = time() + $webdb['time'] * 60; $_POST[loginname] && ($_POST[loginname] = filtrate($_POST[loginname])); $_POST[loginpwd] && ($_POST[loginpwd] = filtrate($_POST[loginpwd])); $FROMURL = filtrate($FROMURL); $WEBURL = filtrate($WEBURL); /** *封IP **/ $IS_BIZ && Limt_IP('ForbidIp'); list($usr_sid, $usr_oltime, $usr_lastvist, $usr_lasturl) = explode("\t", get_cookie('USR')); if (!$usr_sid) { $usr_sid = rands(8); } unset($_ENV, $HTTP_COOKIE, $HTTP_ENV_VARS, $_REQUEST, $HTTP_POST_VARS, $HTTP_GET_VARS, $HTTP_POST_FILES, $HTTP_COOKIE_VARS); $db = new MYSQL_DB(); unset($web_admin, $sort_admin, $lfjid, $lfjuid, $lfjpwd, $lfjdb, $groupdb); $usr_oltime = intval($usr_oltime); /*用户登录模块*/ if ($webdb[passport_type] && is_file(ROOT_PATH . "inc/passport/{$webdb[passport_type]}.php")) { require_once ROOT_PATH . "inc/passport/{$webdb[passport_type]}.php"; $userDB = new qb_user(); $lfjdb = PassportUserdb(); } else { $TB = array("table" => "{$pre}members", "uid" => "uid", "username" => "username", "password" => "password"); $userDB = new qb_user(); $lfjdb = $userDB->login_info(); } //同步后台登录 if ($_COOKIE["adminID"] && ($detail = mymd5($_COOKIE["adminID"], 'DE', $onlineip))) { unset($_uid, $_username, $_password);