Print the auth ldap form
public showForm ( $ID, $options = [] ) : Nothing | ||
$ID | integer ID of the item | |
$options | array - target for the form | |
Результат | Nothing | (display) |
Html::back(); } else { if (isset($_POST["test_ldap_replicate"])) { foreach ($_POST["test_ldap_replicate"] as $replicate_id => $value) { $replicate = new AuthLdapReplicate(); $replicate->getFromDB($replicate_id); if (AuthLdap::testLDAPConnection($_POST["id"], $replicate_id)) { //TRANS: %s is the description of the test $_SESSION["LDAP_TEST_MESSAGE"] = sprintf(__('Test successful: %s'), sprintf(__('Replicate %s'), $ldap->fields["name"])); } else { //TRANS: %s is the description of the test $_SESSION["LDAP_TEST_MESSAGE"] = sprintf(__('Test failed: %s'), sprintf(__('Replicate %s'), $ldap->fields["name"])); } } Html::back(); } else { if (isset($_POST["add_replicate"])) { $replicate = new AuthLdapReplicate(); unset($_POST["next"]); unset($_POST["id"]); $replicate->add($_POST); Html::back(); } } } } } } Html::header(AuthLDAP::getTypeName(1), $_SERVER['PHP_SELF'], 'config', 'extauth', 'ldap'); $config_ldap->showForm($_GET["id"], $_GET); Html::footer();