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


PHP phpCAS::logoutWithUrl方法代码示例

本文整理汇总了PHP中phpCAS::logoutWithUrl方法的典型用法代码示例。如果您正苦于以下问题:PHP phpCAS::logoutWithUrl方法的具体用法?PHP phpCAS::logoutWithUrl怎么用?PHP phpCAS::logoutWithUrl使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在phpCAS的用法示例。


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

示例1: logout

 /**
  * Logout the user form the current symfony application and from the
  *  CAS server
  * @param  boolean $onlyLocal   Set it to true, to logout from the application, but stay login in the CAS
  */
 public function logout($url = null, $onlyLocal = false)
 {
     parent::signOut();
     $this->username = null;
     if (!$onlyLocal) {
         sfCAS::initPhpCAS();
         if (!empty($url)) {
             phpCAS::logoutWithUrl($url);
         } else {
             phpCas::logout();
         }
     }
 }
开发者ID:TheoJD,项目名称:portail,代码行数:18,代码来源:sfUTCCASUser.class.php

示例2: logout

 public function logout()
 {
     $logout_redirect_url = getConfig('casldap_logout_redirect_url');
     $_SESSION['adminloggedin'] = "";
     $_SESSION['logindetails'] = "";
     //destroy the session
     session_destroy();
     if (!getConfig('cas_disable_logout')) {
         self::init_cas_client();
         phpCAS::logoutWithUrl($logout_redirect_url);
     }
     header("Location: {$logout_redirect_url}");
     exit;
 }
开发者ID:brenard,项目名称:phplist-casldap-plugin,代码行数:14,代码来源:CASLdapPlugin.php

示例3: deconnexion_CAS

function deconnexion_CAS($url = "")
{
    // import de la librairie CAS
    include LIBRARY_PATH . 'CAS/CAS.php';
    // import des parametres du serveur CAS
    $config_CAS_host = $_SESSION['config']['CAS_host'];
    $config_CAS_portNumber = $_SESSION['config']['CAS_portNumber'];
    $config_CAS_URI = $_SESSION['config']['CAS_URI'];
    global $connexionCAS;
    // initialisation phpCAS
    if ($connexionCAS != "active") {
        $CASCnx = phpCAS::client(CAS_VERSION_2_0, $config_CAS_host, $config_CAS_portNumber, $config_CAS_URI);
        $connexionCAS = "active";
    }
    phpCAS::logoutWithUrl($url);
}
开发者ID:TexGG,项目名称:Libertempo,代码行数:16,代码来源:fonction.php

示例4: get_path

    die;
}
// include path library
include_once get_path('incRepositorySys') . '/lib/thirdparty/cas/CAS.php';
// DB table definition
$tbl_mdb_names = claro_sql_get_main_tbl();
$tbl_user = $tbl_mdb_names['user'];
if (!isset($_SESSION['init_CasCheckinDone']) || $logout || basename($_SERVER['SCRIPT_NAME']) == 'login.php' && isset($_REQUEST['authModeReq']) && $_REQUEST['authModeReq'] == 'CAS' || isset($_REQUEST['fromCasServer'])) {
    phpCAS::client(CAS_VERSION_2_0, get_conf('claro_CasServerHostUrl'), get_conf('claro_CasServerHostPort', 443), get_conf('claro_CasServerRoot', ''), FALSE);
    phpCAS::setNoCasServerValidation();
    if ($logout) {
        $userLoggedOnCas = false;
        $logout_url = (isset($_SERVER['HTTPS']) && ($_SERVER['HTTPS'] == 'on' || $_SERVER['HTTPS'] == 1) ? 'https://' : 'http://') . $_SERVER['HTTP_HOST'] . get_conf('urlAppend') . '/index.php';
        if (get_conf('claro_CasGlobalLogout')) {
            if (phpCAS::checkAuthentication()) {
                phpCAS::logoutWithUrl($logout_url);
            }
        } else {
            claro_redirect($logout_url);
            die;
        }
    } elseif (basename($_SERVER['SCRIPT_NAME']) == 'login.php') {
        // set the call back url
        if (isset($_REQUEST['sourceUrl'])) {
            $casCallBackUrl = base64_decode($_REQUEST['sourceUrl']);
        } else {
            $casCallBackUrl = (isset($_SERVER['HTTPS']) && ($_SERVER['HTTPS'] == 'on' || $_SERVER['HTTPS'] == 1) ? 'https://' : 'http://') . $_SERVER['HTTP_HOST'] . get_conf('urlAppend') . '/';
        }
        $casCallBackUrl .= (strstr($casCallBackUrl, '?') ? '&' : '?') . 'fromCasServer=true';
        if ($_SESSION['_cid']) {
            $casCallBackUrl .= (strstr($casCallBackUrl, '?') ? '&' : '?') . 'cidReq=' . urlencode($_SESSION['_cid']);
开发者ID:rhertzog,项目名称:lcs,代码行数:31,代码来源:casProcess.inc.php


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