Skip to content
Snippets Groups Projects
Commit fc8d8b84 authored by Tim Steiner's avatar Tim Steiner
Browse files

Move the UNL CAS logout link modification code from a javascript call to the...

Move the UNL CAS logout link modification code from a javascript call to the <link rel="logout"> tag.
Also add the return url to cas logouts.

git-svn-id: file:///tmp/wdn_thm_drupal/branches/drupal-7.x@117 20a16fea-79d4-4915-8869-1ea9d5ebf173
parent f5eb7f28
No related branches found
No related tags found
No related merge requests found
......@@ -94,7 +94,7 @@ function unl_cas_form_alter(&$form, $form_state, $form_id)
function unl_cas_user_logout($account)
{
$cas = unl_cas_get_adapter();
drupal_goto($cas->getLogoutUrl());
drupal_goto($cas->getLogoutUrl(url('<front>', array('absolute' => TRUE))));
}
function unl_cas_import_user($username)
......@@ -120,13 +120,3 @@ function unl_cas_import_user($username)
return $user;
}
function unl_cas_page_alter(&$page)
{
$logoutUrl = url('user/logout');
$ssoScript = <<<EOF
<script type="text/javascript">
WDN.idm.setLogoutURL('$logoutUrl');
</script>
EOF;
$page['page_bottom']['sso']['#markup'] = $ssoScript;
}
......@@ -39,6 +39,7 @@ $t->head .= PHP_EOL
. $styles . PHP_EOL
. $scripts . PHP_EOL
. '<link href="' . url('<front>', array('absolute' => TRUE)) . '" rel="home" />' . PHP_EOL
. '<link rel="logout" href="user/logout" title="Log out of myapp" />' . PHP_EOL
;
if (theme_get_setting('use_base')) {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment