if (strtoupper(CHARSET) == 'GBK') { $arrOauthInfo = kekezu::utftogbk($arrOauthInfo); } $objLogin = new keke_user_login_class(); $arrBindInfo = keke_register_class::is_oauth_bind($type, $arrOauthInfo['account']); if ($_SESSION[$type . '_oauthInfo'] && $arrBindInfo && !$is_binding) { $_SESSION[$type . '_oauthInfo'] = null; $arrUserInfo = kekezu::get_user_info($arrBindInfo['uid']); $loginUserInfo = $objLogin->oauth_user_login($arrUserInfo['username'], $arrUserInfo['password'], null, 1); $objLogin->save_user_info($loginUserInfo, 1); } $inter = $kekezu->_sys_config['user_intergration']; $intLoginTimes = intval($_SESSION['login_times']); if (kekezu::submitcheck(isset($formhash)) || isset($login_type) == 3) { if ($code) { $strCodeCheck = kekezu::check_secode($code); if ($strCodeCheck != 1) { $tips['errors']['code'] = $strCodeCheck; kekezu::show_msg($tips, NULL, NULL, NULL, 'error'); } } $strCode = isset($code) ? $code : ""; $intLoginType = isset($login_type) ? $login_type : ""; $ckb_cookie = isset($ckb_cookie) ? $ckb_cookie : ""; if (strtoupper(CHARSET) == 'GBK') { $account = kekezu::utftogbk($account); } $arrUserInfo = $objLogin->user_login($account, $password, $strCode, $intLoginType, 1); db_factory::execute("delete from " . TABLEPRE . "witkey_space where uid =" . intval($arrBindInfo['uid'])); db_factory::execute("delete from " . TABLEPRE . "witkey_shop where uid=" . intval($arrBindInfo['uid'])); db_factory::execute("delete from " . TABLEPRE . "witkey_member where uid=" . intval($arrBindInfo['uid']));
$tips['errors']['account'] = '账号不存在'; kekezu::show_msg($tips, NULL, NULL, NULL, 'error'); break; case 'email': $arrUserInfo = keke_user_class::getUserInfoByEmail($account); break; case 'username': $arrUserInfo = keke_user_class::getUserInfoByUsername($account); break; } if (!$arrUserInfo) { $tips['errors']['account'] = '账号不存在'; kekezu::show_msg($tips, NULL, NULL, NULL, 'error'); } if ($getPasswordCode) { $strCodeCheck = kekezu::check_secode($getPasswordCode); if ($strCodeCheck != 1) { $tips['errors']['code'] = $strCodeCheck; kekezu::show_msg($tips, NULL, NULL, NULL, 'error'); } } kekezu::show_msg('', "index.php?do=retrieve&strStep=step2&account={$account}", NULL, NULL, 'ok'); } break; case "step2": if (kekezu::submitcheck($formhash)) { $strAccount = strval($account); $arrUserInfo = kekezu::get_user_info($strAccount, true); $arrPassInfo = reset_set_password($arrUserInfo); $arrNotifyArr = array('用户名' => $arrUserInfo['username'], '网站名称' => $kekezu->_sys_config['website_name'], '密码' => $arrPassInfo['code'], '安全码' => $arrPassInfo['sec_code']); keke_shop_class::notify_user($arrUserInfo['uid'], $arrUserInfo['username'], 'get_password', '找回密码', $arrNotifyArr, 2);