ldap_list + Novell eDirectory
| From: | Daniel Bray | Date: | Fri, 15 Aug 2003 00:36:17 +0000 |
| Subject: | ldap_list + Novell eDirectory | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-159623@lists.php.net to get a copy of this message | ||
I am trying to list out some printers in our Novell tree. The server
that I am hitting is a Netware 6 server, running eDirectory 8. Here is
the code I am using (simplified):
--------begin code------------------
$printer_dn = "ou=$facility_selected, $basedn";
$printer_list = ldap_list($ldapconnect, $printer_dn, "cn=*");
ldap_sort ($ldapconnect, $printer_list,"cn");
$printer_list_results = ldap_get_entries($ldapconnect, $printer_list);
if ($printer_list_results != 0)
{
echo "\t<blockquote>\n";
for ($p=0; $p<$printer_list_results["count"]; $p++)
{
$printer = $printer_list_results[$p]["cn"][0];
echo "$printer <br>";
}
echo "\t</blockquote>\n";
}
--------end code------------------
Problem with this, is that if the containers has let's say 5 printers, and
just one of them has a DS problem, then the entire list is corrupted and
will only return "LDAP Error: Invalid DN syntax" to the screen.
The list will not return ANY of the printers.
Thanks for your time,
DB