ID: 11343 Updated by: sniper Reported By: [EMAIL PROTECTED] Old-Status: Open Status: Closed Bug Type: Feature/Change Request Operating system: PHP Version: 4.0.5 Assigned To: Comments: Previous Comments: --------------------------------------------------------------------------- [2001-06-07 22:05:54] [EMAIL PROTECTED] Looking at ../etc/ldap/ldap.c: /* {{{ proto int ldap_search(int link, string base_dn, string filter [, array attrs [, int attrsonly [, int sizelimit [, int timelimit [, int deref]]]]]) Search LDAP tree under base_dn */ PHP_FUNCTION(ldap_search) { php_ldap_do_search(INTERNAL_FUNCTION_PARAM_PASSTHRU, LDAP_SCOPE_SUBTREE); } /* }}} */ I believe we should be able to specify the search base and not have it forced to SUBTREE. To access the SCHEMA in the directory you can do the following search with ldapsearch: ldapsearch -h 192.168.0.1 -D cn=admin,o=company -w password -s base -b cn=schema objectclass=* If you leave out the "-s base" you get this error: ldap_search: No such object Which is the same effect in PHP. Can we add an optional parameter in the ldap_search funtion to specify the search scope: one, base, subtree. I'm trying to write a tool to export the schema and display it using PHP. Any help would be appreciated. Regards, Jon. --------------------------------------------------------------------------- ATTENTION! Do NOT reply to this email! To reply, use the web interface found at http://bugs.php.net/?id=11343&edit=2 -- PHP Development Mailing List <http://www.php.net/> To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]