IT. Expert System.

PHP

Sort LDAP result entries


ldap_sort

(PHP 4 >= 4.2.0, PHP 5)

ldap_sortSort LDAP result entries

Description

bool ldap_sort ( resource $link , resource $result , string $sortfilter )

Sort the result of a LDAP search, returned by ldap_search().

Parameters

link

An LDAP link identifier, returned by ldap_connect().

result

An search result identifier, returned by ldap_search().

sortfilter

The attribute to use as a key in the sort.

Examples

Sorting the the result of a search.

Example #1 LDAP sort

<?php
     
// $ds is a valid link identifier (see ldap_connect)

     
$dn        'ou=example,dc=org';
     
$filter    '(|(sn=Doe*)(givenname=John*))';
     
$justthese = array('ou''sn''givenname''mail');

     
$sr ldap_search($ds$dn$filter$justthese);

     
// Sort
     
ldap_sort($ds$sr'sn');

     
// Retrieving the data
     
$info ldap_get_entries($ds$sr);



Content

Android Reference

Java basics

Java Enterprise Edition (EE)

Java Standard Edition (SE)

SQL

HTML

PHP

CSS

Java Script

MYSQL

JQUERY

VBS

REGEX

C

C++

C#

Design patterns

RFC (standard status)

RFC (proposed standard status)

RFC (draft standard status)

RFC (informational status)

RFC (experimental status)

RFC (best current practice status)

RFC (historic status)

RFC (unknown status)

IT dictionary

License.
All information of this service is derived from the free sources and is provided solely in the form of quotations. This service provides information and interfaces solely for the familiarization (not ownership) and under the "as is" condition.
Copyright 2016 © ELTASK.COM. All rights reserved.
Site is optimized for mobile devices.
Downloads: 285 / 158667803. Delta: 0.00174 с