LDAP Problem

The release related discussions, plans and questions.
Locked
vidhyavenkatachalam
TestLink user
Posts: 3
Joined: Fri Jun 27, 2008 6:53 am
Location: Bangalore

LDAP Problem

Post by vidhyavenkatachalam »

Hi,
In TetsLink 1.7 am making use of LDAP. I am able to execute the following functions like:

$ldapConnection = ldap_connect($ldap_server,$ldap_port);
$ldapBind = ldap_bind($ldapConnection,$dn,$userName,$passWord);

but I am not able to execute the function :

if($ldapBind) {
$arrayList = array("mail","sn");
$ldapSearch = ldap_search($ldapConnection,$dn,$filter,$arrayList);
$info = ldap_get_entries($ldapConnection, $ldapSearch);
}

The error message I am obtaining is as follows :-

Warning: ldap_search(): supplied argument is not a valid ldap link resource in C:\www\testlink\lib\functions\ldap_api.php on line 115

Can anyone suggest me the reason and give me a solution for it.

Regards,
Vidhya Venkatachalam
mtwom
TestLink user
Posts: 1
Joined: Tue Sep 09, 2008 2:50 pm

Post by mtwom »

Hi, do you have $ldapConnection != null?, probably that is null or empty review the code in the lines:

$ldapConnection = ldap_connect($ldap_server,$ldap_port);
$ldapBind = ldap_bind($ldapConnection,$dn,$userName,$passWord);

i hope you do understand me, sorry my bad English. :oops:
Locked