ldap_bind() - Unable to bind to server: Protocol error

in unable •  4 years ago 

Note that you have to specify the protocol version prior to making a call to ldap_bind, when the server is expecting LDAP protocol version 3. If you do not, you will receive a warning and fail to bind, such as:

ldap_bind(): Unable to bind to server: Protocol error

In order to avoid this, make this call:

ldap_set_option($ds, LDAP_OPT_PROTOCOL_VERSION, 3);

?>

Where $ds is the result returned by ldap_connect(...);

web-development-technology-1.png

Authors get paid when people like you upvote their post.
If you enjoyed what you read here, create your account today and start earning FREE STEEM!