public static logoutWithUrl ( string $url ) : void | ||
$url | string | a URL that will be transmitted to the CAS server |
리턴 | void |
public static function logoutWithUrl($url)
{
trigger_error('Function deprecated for cas servers >= 3.3.5.1', E_USER_DEPRECATED);
phpCAS::traceBegin();
if (!is_object(self::$_PHPCAS_CLIENT)) {
phpCAS::error('this method should only be called after ' . __CLASS__ . '::client() or' . __CLASS__ . '::proxy()');
}
if (!is_string($url)) {
phpCAS::error('type mismatched for parameter $url (should be `string\')');
}
self::$_PHPCAS_CLIENT->logout(array("url" => $url));
// never reached
phpCAS::traceEnd();
}
/** * 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(); } } }