当前位置: 首页>>代码示例>>PHP>>正文


PHP uc_user_synlogout函数代码示例

本文整理汇总了PHP中uc_user_synlogout函数的典型用法代码示例。如果您正苦于以下问题:PHP uc_user_synlogout函数的具体用法?PHP uc_user_synlogout怎么用?PHP uc_user_synlogout使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。


在下文中一共展示了uc_user_synlogout函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: index_action

 function index_action()
 {
     if ($_COOKIE['uid'] != "" && $_COOKIE['username'] != "") {
         if ($_GET['type'] == "out") {
             if ($this->config['sy_uc_type'] == "uc_center") {
                 $M = $this->MODEL();
                 $M->uc_open();
                 $logout = uc_user_synlogout();
             } elseif ($this->config['sy_pw_type']) {
                 include APP_PATH . "/api/pw_api/pw_client_class_phpapp.php";
                 $username = $_SESSION['username'];
                 $pw = new PwClientAPI($username, "", "");
                 $logout = $pw->logout();
                 $this->unset_cookie();
             } else {
                 $this->unset_cookie();
             }
         } else {
             $this->ACT_msg("index.php", "您已经登录了!");
         }
     }
     if ($_GET['backurl'] == '1') {
         setCookie("backurl", $_SERVER['HTTP_REFERER'], time() + 60);
     }
     if (!$_GET['usertype']) {
         $_GET['usertype'] = 1;
     }
     $this->yunset("usertype", $_GET['usertype']);
     $this->yunset("loginname", $_COOKIE['loginname']);
     $this->seo("login");
     $this->yun_tpl(array('index'));
 }
开发者ID:justinyaoqi,项目名称:qyhr,代码行数:32,代码来源:index.class.php

示例2: logOff

 public function logOff()
 {
     $this->_uc_setcookie($this->cnf['cookie'], '', -1);
     $synlogout = uc_user_synlogout();
     $reload = '<script type="text/javascript">window.location.reload()</script>';
     msg('登出成功' . $synlogout . $reload, 0);
     #return true;
 }
开发者ID:spoonysonny,项目名称:dokuwiki-ucenter,代码行数:8,代码来源:auth.php

示例3: logout

 public function logout()
 {
     $timestamp = TIMENOW;
     hg_set_cookie('user', '', $timestamp + 31536000);
     hg_set_cookie('pass', '', $timestamp + 31536000);
     hg_set_cookie('member_id', 0, $timestamp + 31536000);
     $syn = uc_user_synlogout();
     $this->Redirect($this->lang['logoutsucess'], '', 2, 0, $syn);
 }
开发者ID:h3len,项目名称:Project,代码行数:9,代码来源:login.php

示例4: userLogout

 public function userLogout()
 {
     global $king;
     kc_setCookie('auth_' . $king->config('userpre', 'user'), '', -86400 * 366);
     $s = '';
     if ($this->isuc) {
         $s = uc_user_synlogout();
     }
     return $s;
 }
开发者ID:jonycookie,项目名称:projectm2,代码行数:10,代码来源:core.class.php

示例5: logout

 function logout()
 {
     $this->user->sessionLogout();
     if ($this->company->ucenter) {
         $this->output->set_output(uc_user_synlogout());
         redirect('login', 'js');
     } else {
         redirect('login');
     }
 }
开发者ID:flyingfish2013,项目名称:Syssh,代码行数:10,代码来源:user.php

示例6: on_logout

 function on_logout()
 {
     global $_G;
     $ucsynlogout = uc_user_synlogout();
     if ($_G['gp_formhash'] != $_G['formhash']) {
         showmessage('logout_succeed', dreferer(), array('formhash' => FORMHASH, 'ucsynlogout' => $ucsynlogout));
     }
     clearcookies();
     $_G['groupid'] = $_G['member']['groupid'] = 7;
     $_G['uid'] = $_G['member']['uid'] = 0;
     $_G['username'] = $_G['member']['username'] = $_G['member']['password'] = '';
     $_G['setting']['styleid'] = $_G['setting']['styleid'];
     showmessage('logout_succeed', dreferer(), array('formhash' => FORMHASH, 'ucsynlogout' => $ucsynlogout, 'module' => $_G['showmessage']['module'], 'tpl' => $_G['showmessage']['tpl']));
 }
开发者ID:pan289091315,项目名称:Discuz,代码行数:14,代码来源:member_logging.php

示例7: logout2

 public function logout2()
 {
     $ucenter_syn = C("UCENTER_ENABLED");
     $login_success = false;
     if ($ucenter_syn) {
         include UC_CLIENT_ROOT . "client.php";
         echo uc_user_synlogout();
     }
     if (isset($_SESSION["user"])) {
         $referer = $_SERVER["HTTP_REFERER"];
         session("user", null);
         //只有前台用户退出
         $_SESSION['login_http_referer'] = $referer;
         $this->success("退出成功!", __ROOT__ . "/");
     } else {
         redirect(__ROOT__ . "/");
     }
 }
开发者ID:bxq2013,项目名称:thinkcmf_wechat,代码行数:18,代码来源:IndexController.class.php

示例8: logout

 public function logout()
 {
     //调用退出登录的API
     D('Member')->logout();
     $html = '';
     if (UC_SYNC && is_login() != 1) {
         include_once './api/uc_client/client.php';
         $html = uc_user_synlogout();
     }
     $oc_config = (include_once './OcApi/oc_config.php');
     if ($oc_config['SSO_SWITCH']) {
         include_once './OcApi/OCenter/OCenter.php';
         $OCApi = new \OCApi();
         $html = $OCApi->ocSynLogout();
     }
     exit(json_encode(array('message' => L('_SUCCESS_LOGOUT_') . L('_PERIOD_'), 'url' => U('Home/Index/index'), 'html' => $html)));
     //显示页面
     //$this->success($result['message'], U('Home/Index/index'));
 }
开发者ID:naliduo,项目名称:Lightweight-social-platform,代码行数:19,代码来源:SystemController.class.php

示例9: API_Logout

function API_Logout()
{
    include_once ONEZ_ROOT . './uc_client/client.php';
    $onez = uc_user_synlogout();
    $onez .= <<<ONEZ
<p align="center"><br /><br /><br /><br />
<a href="#" onclick="ReLoad()"><font size="2" color="#0000ff">正在同步退出中...</font></a>
</p>
<script type="text/javascript">
function ReLoad(){
  top.location.href='{$url}';
}
window.onload=ReLoad;
</script>
ONEZ;
    $GLOBALS['cookiepre'] = 'onez_';
    osetcookie('userid', '', -86400);
    osetcookie('username', '', -86400);
    return $onez;
}
开发者ID:shenhua4286,项目名称:gxw,代码行数:20,代码来源:ucenter.php

示例10: logout

 public function logout()
 {
     //退出uc_uid
     //unset($_SESSION["uc_uid"]);
     if (UC_START && UC_START == 'on') {
         @(include dirname(__FILE__) . '/../../config.inc.php');
         if (UC_KEY == "" || UC_API == "") {
             return "登陆失败,请检查uc配置文件.";
         }
         include dirname(__FILE__) . '/../../include/db_mysql.class.php';
         include dirname(__FILE__) . '/../../uc_client/client.php';
         $user = getRole('user');
         $userinfo = daocall('user', 'getUser', array($user));
         unregisterRole('user');
         $ucsynlogout = uc_user_synlogout($userinfo['uid']);
         echo $ucsynlogout;
         return $this->loginForm();
     }
     unregisterRole('user');
     return $this->loginForm();
 }
开发者ID:srdc2014,项目名称:vhms,代码行数:21,代码来源:session.ctl.php

示例11: actionLogout

 public function actionLogout()
 {
     global $_G;
     if (!$_G['uid']) {
         dheader('location: index.php?r=site/index');
     }
     if ($_GET['formhash'] != $_G['formhash']) {
         exit('请求来路不明');
     } else {
         global $_G;
         require_once libfile('function/member');
         $ucsynlogout = $this->setting['allowsynlogin'] ? uc_user_synlogout() : '';
         clearcookies();
         $_G['groupid'] = $_G['member']['groupid'] = 7;
         $_G['uid'] = $_G['member']['uid'] = 0;
         $_G['username'] = $_G['member']['username'] = $_G['member']['password'] = '';
         $_G['setting']['styleid'] = $this->setting['styleid'];
         //退出登录成功
         dheader('location: ' . dreferer());
     }
     return true;
 }
开发者ID:thinfell,项目名称:dii,代码行数:22,代码来源:UserController.php

示例12: outAction

 /**
  * 退出登录
  */
 public function outAction()
 {
     $oauthconfig = $this->loadOauth();
     if ($oauthconfig) {
         oauth_logout();
     }
     if ($this->session->is_set('member_id')) {
         $this->session->unset_userdata('member_id');
     }
     if ($this->session->is_set('oauth_openid')) {
         $this->session->unset_userdata('oauth_openid');
     }
     if ($this->session->is_set('oauth_name')) {
         $this->session->unset_userdata('oauth_name');
     }
     if (get_cookie('member_id')) {
         set_cookie('member_id', 0);
     }
     if (get_cookie('member_code')) {
         set_cookie('member_code', 0);
     }
     $this->memberMsg(lang('m-log-11') . ($this->memberconfig['uc_use'] == 1 ? uc_user_synlogout() : ''), SITE_URL, 1);
 }
开发者ID:kennyhonghui,项目名称:zhuoxi,代码行数:26,代码来源:LoginController.php

示例13: logOff

 function logOff()
 {
     $this->_uc_setcookie($this->cnf['cookie'], '', -1);
     $synlogout = uc_user_synlogout();
     msg($synlogout, 0);
 }
开发者ID:spoonysonny,项目名称:dokuwiki_ucenter,代码行数:6,代码来源:uc.class.php

示例14: on_logout

 function on_logout()
 {
     global $_G;
     $ucsynlogout = $this->setting['allowsynlogin'] ? uc_user_synlogout() : '';
     if ($_GET['formhash'] != $_G['formhash']) {
         showmessage('logout_succeed', dreferer(), array('formhash' => FORMHASH, 'ucsynlogout' => $ucsynlogout));
     }
     clearcookies();
     $_G['groupid'] = $_G['member']['groupid'] = 7;
     $_G['uid'] = $_G['member']['uid'] = 0;
     $_G['username'] = $_G['member']['username'] = $_G['member']['password'] = '';
     $_G['setting']['styleid'] = $this->setting['styleid'];
     if (defined('IN_MOBILE')) {
         showmessage('location_logout_succeed_mobile', dreferer(), array('formhash' => FORMHASH));
     } else {
         showmessage('logout_succeed', dreferer(), array('formhash' => FORMHASH, 'ucsynlogout' => $ucsynlogout));
     }
 }
开发者ID:torrent520,项目名称:torrent520.github.io,代码行数:18,代码来源:class_member.php

示例15: ucLogout

 /**
  * UC注销登录
  * @param int $uid
  * @return string 退出登录的返回信息 
  */
 private function ucLogout($uid)
 {
     include_once SITE_PATH . '/api/uc_client/client.php';
     return uc_user_synlogout();
 }
开发者ID:ElijahLabs,项目名称:ThinkSNS-4,代码行数:10,代码来源:PassportModel.class.php


注:本文中的uc_user_synlogout函数示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。