Hi, Have you tried in the php.ini to setup error_reporting to E_ALL and display error messages (display_errors = On) ? I had a similar problem 2 days ago and it was due to another mistake in my PHP code. But i did not get any error message or more precisely, i did not get any WARNING message. since i did this i repaired my PHP mistake. My code relative to LDAP was good and without any mistake. Try this and let us know if you do not have such situation. Alain On 8/21/07, Dan Shirah <mrsquash2@xxxxxxxxx> wrote: > > Nothing is being blocked since both servers are inside the DMZ. > > On 8/21/07, Daniel Brown <parasane@xxxxxxxxx> wrote: > > > > On 8/21/07, Dan Shirah <mrsquash2@xxxxxxxxx> wrote: > > > Okay, hopefully someone can help me out here. I've gone over ldap at > > > php.net and multiple other sites but can't get it to work. Everytime I > > run > > > the query my results are "0 entries returned". > > > > > > My AD tree is: CN=Users,DC=domain,DC=us. I have the AD Server set so > > that > > > anonymous access to retrieve information is enabled. > > > > > > Below is my code. Any ideas? > > > > > > > > > <?php > > > $ldap_host = "AD Server"; > > > $ldap_port = "389"; > > > $base_dn = "DC=domain,DC=us"; > > > $filter = "(CN=users)"; > > > $connect = ldap_connect( $ldap_host, $ldap_port); > > > ldap_set_option($connect, LDAP_OPT_PROTOCOL_VERSION, 3); > > > > > > $bind = ldap_bind($connect); > > > $read = ldap_search($connect, $base_dn, $filter); > > > > > > $info = ldap_get_entries($connect, $read); > > > echo $info["count"]." entries returned<BR><BR>"; > > > for($row = 0; $row<$info["count"]; $row++) > > > { > > > for($column = 0; $column<$info[$row]["count"]; $column++) > > > { > > > $data = $info[$row][$column]; > > > echo $data.":".$info[$row][$data][0]."<BR>"; > > > } > > > echo "<BR>"; > > > } > > > ldap_close($connect); > > > ?> > > > > > > > This may be kind of a dumb question.... but did you check your > > firewall settings? > > > > -- > > Daniel P. Brown > > [office] (570-) 587-7080 Ext. 272 > > [mobile] (570-) 766-8107 > > > > Hey, PHP-General list.... > > 50% off for life on web hosting plans $10/mo. or more at > > http://www.pilotpig.net/. > > Use the coupon code phpgeneralaug07 > > Register domains for about $0.01 more than what it costs me at > > http://domains.pilotpig.net/. > > > -- Alain ------------------------------------ Windows XP SP2 PostgreSQL 8.2.3 Apache 2.2.4 PHP 5.2.3