本文整理汇总了PHP中phpCAS::getServerLogoutURL方法的典型用法代码示例。如果您正苦于以下问题:PHP phpCAS::getServerLogoutURL方法的具体用法?PHP phpCAS::getServerLogoutURL怎么用?PHP phpCAS::getServerLogoutURL使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类phpCAS
的用法示例。
在下文中一共展示了phpCAS::getServerLogoutURL方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: main
/**
* [Put your description here]
*/
function main($content, $conf)
{
$this->conf = $conf;
$this->pi_setPiVarDefaults();
$this->pi_USER_INT_obj = 1;
// Configuring so caching is not expected. This value means that no cHash params are ever set. We do this, because it's a USER_INT object!
$this->pi_loadLL();
$this->typeExecution = "prod";
$urlCas = "none";
$portCas = "none";
if ($this->typeExecution == "dev") {
$urlCas = "xinf-devlinux.intranet.haras-nationaux.fr";
$portCas = 7777;
} else {
if ($this->typeExecution == "prod") {
$urlCas = "cerbere.haras-nationaux.fr";
$portCas = 443;
}
}
session_start();
if (isset($_GET["action"]) && $_GET["action"] == "disconnect") {
phpCAS::setDebug();
phpCAS::client(CAS_VERSION_2_0, $urlCas, $portCas, 'cas', 'true');
$ur = phpCAS::getServerLogoutURL();
phpCAS::killSession();
//Suppression de la sesssion de harasire
setcookie("netid", "", time() - 3600, "/", ".haras-nationaux.fr");
//$urCid = "http://www4.haras-nationaux.fr/cid-internet-web/InvalidateSessionServlet?service=".$ur;
$content .= '<IFRAME src="' . $ur . '" frameborder="no" height="600" width="670"></IFRAME>';
return $this->pi_wrapInBaseClass($content);
}
}
示例2: RWSPLOCas
function RWSPLOCas($r_csp)
{
global $RWSESL3;
if (isset($_SESSION['rwscas']['cookiejar'])) {
$r_ckf = $_SESSION['rwscas']['cookiejar'];
}
if (empty($r_csp->config->hostname) || !$r_csp->config->logoutcas) {
if (isset($r_ckf)) {
if (file_exists($r_ckf)) {
unlink($r_ckf);
}
unset($_SESSION['rwscas']['cookiejar']);
}
unset($_SESSION['rwscas']);
return;
}
list($r_v1, $r_v2, $r_v3) = explode(".", phpCAS::getVersion());
$r_csp->connectCAS();
$r_lou = phpCAS::getServerLogoutURL();
$r_ch = curl_init();
curl_setopt($r_ch, CURLOPT_URL, $r_lou);
curl_setopt($r_ch, CURLOPT_HTTPGET, true);
curl_setopt($r_ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($r_ch, CURLOPT_FOLLOWLOCATION, true);
curl_setopt($r_ch, CURLOPT_FAILONERROR, true);
curl_setopt($r_ch, CURLOPT_TIMEOUT, 30);
curl_setopt($r_ch, CURLOPT_SSL_VERIFYHOST, false);
curl_setopt($r_ch, CURLOPT_SSL_VERIFYPEER, false);
curl_setopt($r_ch, CURLOPT_USERAGENT, "PHP");
if (isset($r_ckf)) {
curl_setopt($r_ch, CURLOPT_COOKIEFILE, $r_ckf);
curl_setopt($r_ch, CURLOPT_COOKIEJAR, $r_ckf);
}
curl_exec($r_ch);
curl_close($r_ch);
if (isset($r_ckf)) {
if (file_exists($r_ckf)) {
unlink($r_ckf);
}
unset($_SESSION['rwscas']['cookiejar']);
}
unset($_SESSION['rwscas']);
session_unset();
session_destroy();
}
示例3: getLogoutRedirect
public function getLogoutRedirect()
{
$_SESSION = array();
session_destroy();
return phpCAS::getServerLogoutURL();
}