Php Programming Code Examples
Php > LDAP Code Examples
Get Attributes
Get Attributes
<?php
// $ds is the link identifier for the directory
// $sr is a valid search result from a prior call to
// one of the ldap directory search calls
$entry = ldap_first_entry($ds, $sr);
$attrs = ldap_get_attributes($ds, $entry);
echo $attrs["count"]." attributes held for this entry:<p>";
for ($i=0; $i<$attrs["count"]; $i )
echo $attrs[$i]."<br>";
?>