X-Git-Url: https://git.sur5r.net/?a=blobdiff_plain;f=login.php;h=5ea09ea7379485c66b4aa5a8d0f57f7011689bef;hb=3f7e9f939d0f0ab92ed49bc783292dd27f4a83af;hp=f7ad08ec1d02c16886ba4aa109bfe49b7123a866;hpb=aa36c490d2218814cb6faa20e31c10b5599d4483;p=contagged diff --git a/login.php b/login.php index f7ad08e..5ea09ea 100644 --- a/login.php +++ b/login.php @@ -1,26 +1,41 @@ - array ('organizationalUnit','top'), + 'ou' => $match[1])); + } + } + + //forward to next page + if(!empty($_SESSION['ldapab']['lastlocation'])){ + header('Location: '.$_SESSION['ldapab']['lastlocation']); + }else{ + header('Location: index.php'); + } + exit; }else{ - $msg = $lang[msg_loginfail];; + $msg = $lang['msg_loginfail'];; } - } +} + +//prepare templates +tpl_std(); +$smarty->assign('msg',$msg); +//display templates +header('Content-Type: text/html; charset=utf-8'); +$smarty->display('login.tpl'); - //prepare templates - tpl_std(); - $smarty->assign('msg',$msg); - //display templates - $smarty->display('header.tpl'); - $smarty->display('login.tpl'); - $smarty->display('footer.tpl'); -?>