From: <te...@us...> - 2004-07-27 20:13:13
|
Update of /cvsroot/tikiwiki/tiki In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv10723 Modified Files: tiki-index.php Log Message: CAS auth: redirect to tiki-login.php instead of showing login module when login is required Index: tiki-index.php =================================================================== RCS file: /cvsroot/tikiwiki/tiki/tiki-index.php,v retrieving revision 1.122 retrieving revision 1.123 diff -u -d -r1.122 -r1.123 --- tiki-index.php 22 Jul 2004 13:08:26 -0000 1.122 +++ tiki-index.php 27 Jul 2004 20:13:03 -0000 1.123 @@ -145,7 +145,10 @@ $is_categorized = FALSE; } if ($is_categorized && isset($tiki_p_view_categories) && $tiki_p_view_categories != 'y') { - if (!isset($user)){ + if (!isset($user) && $tikilib->get_preference('auth_method', 'tiki') == 'cas') { + header('location: tiki-login.php'); + exit; + } elseif (!isset($user)) { $smarty->assign('msg',$smarty->fetch('modules/mod-login_box.tpl')); $smarty->assign('errortitle',tra("Please login")); } else { @@ -163,7 +166,10 @@ // Now check permissions to access this page if($tiki_p_view != 'y') { - if (!isset($user)){ + if (!isset($user) && $tikilib->get_preference('auth_method', 'tiki') == 'cas') { + header('location: tiki-login.php'); + exit; + } elseif (!isset($user)) { $smarty->assign('msg',$smarty->fetch('modules/mod-login_box.tpl')); $smarty->assign('errortitle',tra("Please login")); } else { |