Y
yawnmoth
I'm trying to connect to an Active Directory server with PHP and am
having some
difficulties. Here's the code I'm using:
<?php
if (!($ldap = ldap_connect('domain.tld'))
{
exit('unable to connect');
}
ldap_bind($ldap, 'username', 'password');
?>
With that code, I get the following error:
Warning: ldap_bind() [function.ldap-bind]: Unable to bind to server:
Invalid credentials in C:\htdocs\test.php on line 10
The thing is... I can connect just fine using Active Directory
Explorer v1.01 using the same info as above. The only thing I
can figure is that Active Directory Explorer is doing something that
PHP doesn't. Maybe it connects to a different port than PHP does by
default? Maybe it appends something to the username?
having some
difficulties. Here's the code I'm using:
<?php
if (!($ldap = ldap_connect('domain.tld'))
{
exit('unable to connect');
}
ldap_bind($ldap, 'username', 'password');
?>
With that code, I get the following error:
Warning: ldap_bind() [function.ldap-bind]: Unable to bind to server:
Invalid credentials in C:\htdocs\test.php on line 10
The thing is... I can connect just fine using Active Directory
Explorer v1.01 using the same info as above. The only thing I
can figure is that Active Directory Explorer is doing something that
PHP doesn't. Maybe it connects to a different port than PHP does by
default? Maybe it appends something to the username?