altAuthGetParams('ldap'); if (!isset($ldap['ldap_edirfilter'])) $ldap['ldap_edirfilter'] == ''; //print_a($ldap); $current_filter = "(&(cn=[USERNAME]){$ldap['ldap_edirfilter']})"; $frm = new form; $text = $frm -> form_open('post',e_SELF); $text .= ""; $text .= ""; $text .= ""; $text .= ""; $text .= ""; $text .= ""; $text .= ""; $text .= ""; $text .= ""; $text .= ""; $this->add_extended_fields(); $text .= $this->alt_auth_get_field_list('ldap',$frm, $ldap, FALSE); $text .= ""; $text .= "
".LDAPLAN_12.""; $text .= $frm -> form_select_open("ldap_servertype"); foreach($server_types as $v) { $sel = (vartrue($ldap['ldap_servertype']) == $v) ? " Selected='selected'" : ''; $text .= $frm -> form_option($v, $sel, $v); } $text .= $frm -> form_select_close(); $text .= "
".LDAPLAN_1.""; $text .= $frm -> form_text("ldap_server", 35, vartrue($ldap['ldap_server']), 120); $text .= "
".LDAPLAN_2.""; $text .= $frm -> form_text("ldap_basedn", 35, vartrue($ldap['ldap_basedn']), 120); $text .= "
".LDAPLAN_14.""; $text .= $frm -> form_text("ldap_ou", 35, vartrue($ldap['ldap_ou']), 60); $text .= "
".LDAPLAN_3.""; $text .= $frm -> form_text("ldap_user", 35, vartrue($ldap['ldap_user']), 120); $text .= "
".LDAPLAN_4.""; $text .= $frm -> form_text("ldap_passwd", 35, vartrue($ldap['ldap_passwd']), 120); $text .= "
".LDAPLAN_5.""; $text .= $frm -> form_select_open("ldap_version"); foreach($ldap_ver as $v) { $sel = ($ldap['ldap_version'] == $v) ? " Selected='selected'" : ""; $text .= $frm -> form_option($v, $sel, $v); } $text .= $frm -> form_select_close(); $text .= "
".LDAPLAN_7."
".LDAPLAN_8."
"; $text .= $frm -> form_text('ldap_edirfilter', 35, $ldap['ldap_edirfilter'], 120); $text .= "
".LDAPLAN_9."
".htmlentities($current_filter)."
".LAN_ALT_27."
"; $text .= e107::getForm()->admin_button("update", LAN_UPDATE,'update'); //$text .= $frm -> form_button('submit', 'update', LDAPLAN_13); $text .= "
\n"; $text .= $frm -> form_close(); e107::getRender()->tablerender(LDAPLAN_6, $mes->render(). $text); e107::getRender()->tablerender(LAN_ALT_40.LAN_ALT_41, $this->alt_auth_test_form('ldap',$frm)); } } $ldapAdmin = new alt_auth_ldap(); $message = ''; if(vartrue($_POST['update'])) { $message .= $ldapAdmin->alt_auth_post_options('ldap'); } if(!function_exists('ldap_connect')) { // $message .= "

".LDAPLAN_11."

"; $mes->addWarning(LDAPLAN_11); } if($message) { e107::getRender()->tablerender('',"
".$message.'
'); } $ldapAdmin->showForm($mes); require_once(e_ADMIN.'footer.php'); function ldap_conf_adminmenu() { alt_auth_adminmenu(); }