dbut amlioration LDAP
This commit is contained in:
parent
7b2d2cf357
commit
f587a8ac77
@ -263,7 +263,6 @@ if (function_exists("ldap_connect"))
|
||||
{
|
||||
// Test ldap_connect
|
||||
$ds = dolibarr_ldap_connect();
|
||||
print "x".$ds;
|
||||
if ($ds)
|
||||
{
|
||||
print img_picto('','info');
|
||||
@ -279,15 +278,18 @@ if (function_exists("ldap_connect"))
|
||||
}
|
||||
|
||||
// Test ldap_getversion
|
||||
if ((dolibarr_ldap_getversion($ds) == 3))
|
||||
if ($ds)
|
||||
{
|
||||
print img_picto('','info');
|
||||
print $langs->trans("LDAPSetupForVersion3").'<br>';
|
||||
}
|
||||
else
|
||||
{
|
||||
print img_picto('','info');
|
||||
print $langs->trans("LDAPSetupForVersion2").'<br>';
|
||||
if ((dolibarr_ldap_getversion($ds) == 3))
|
||||
{
|
||||
print img_picto('','info');
|
||||
print $langs->trans("LDAPSetupForVersion3").'<br>';
|
||||
}
|
||||
else
|
||||
{
|
||||
print img_picto('','info');
|
||||
print $langs->trans("LDAPSetupForVersion2").'<br>';
|
||||
}
|
||||
}
|
||||
|
||||
// Test ldap_bind
|
||||
|
||||
@ -57,13 +57,12 @@ function dolibarr_ldap_connect()
|
||||
if ($ldapconnect)
|
||||
{
|
||||
ldap_set_option($ldapconnect, LDAP_OPT_PROTOCOL_VERSION, $conf->global->LDAP_SERVER_PROTOCOLVERSION);
|
||||
return $ldapconnect;
|
||||
}
|
||||
else
|
||||
{
|
||||
$this->err .= ldap_error($ldapconnect);
|
||||
}
|
||||
|
||||
return $ldapconnect;
|
||||
}
|
||||
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user