2 require_once('init.php');
4 $msg = $lang['msg_login'];
5 if(isset($_REQUEST['username'])){
6 if (empty($_REQUEST['password'])) { $_REQUEST['password']=''; }
7 if (do_ldap_bind($_REQUEST['username'],$_REQUEST['password'])){
9 if(!empty($_SESSION['ldapab']['lastlocation'])){
10 header('Location: '.$_SESSION['ldapab']['lastlocation']);
12 header('Location: index.php');
16 $msg = $lang['msg_loginfail'];;
22 $smarty->assign('msg',$msg);
24 header('Content-Type: text/html; charset=utf-8');
25 $smarty->display('login.tpl');