Details
Description
I made two functions inside Zend_Ldap->search.
public function search($filter, $basedn = null, $scope = self::SEARCH_SCOPE_SUB, array $attributes = array(), $sort = null, $sortDir = null, $resultChangeCase = null, $collectionClass = null)
sortDir would be:
if (strtolower($sortDir) == 'desc') { array_reverse($result, true); }
resultChangeCase would be:
$result = Zend_Ldap->search(...); if ($resultChangeCase != null) { if (!in_array($resultChangeCase, array('strtolower' ,'strtoupper', 'ucfirst', 'ucwords'))) { throw new Exception('...'); } array_walk_recursive($result, function(&$value, $key, $func) { $value = $func($value); }, $resultChangeCase); }
I hope you guys enjoy it! ![]()
Issue Links
| This issue is related to: | ||||
| ZF-8263 | Zend_Ldap converts attribute names of ldap objects to lowercase |
|
|
|
Forgot to describe $result.