[Date Prev][Date Next] [Chronological] [Thread] [Top]

Re: how do you enable protocol version 2 support?

fre, 2003-03-28 kl. 23:14 skrev BsD JuNkiE:

> ok, i just added....
> ldap_set_option($connectId, LDAP_OPT_PROTOCOL_VERSION, 3);
> to my php.ini  file but it did not do any good. i am still getting:
> Could not bind to ldap server: Protocol error

Ermm .. this is not for php.ini; it's a piece of standard php code
("standard" here means "employed by everyone"). Read up on, and
practice, php4 ldap coding (included in the standard php manual):

$ds=ldap_connect($Host, $Port);
if (ldap_set_option($ds, LDAP_OPT_PROTOCOL_VERSION, 3)) {
    print "Using LDAPv3 protocol <p>";
    } else
      if (ldap_set_option($ds, LDAP_OPT_PROTOCOL_VERSION, 2)) {
        print "Using LDAPv2 protocol <p>";




Tony Earnshaw

e-post:		tonni@billy.demon.nl
www:		http://www.billy.demon.nl