1--TEST-- 2ldap_count_entries() - Basic counting LDAP entries 3--CREDITS-- 4Patrick Allaert <patrickallaert@php.net> 5# Belgian PHP Testfest 2009 6--EXTENSIONS-- 7ldap 8--SKIPIF-- 9<?php require_once('skipifbindfailure.inc'); ?> 10--FILE-- 11<?php 12require "connect.inc"; 13 14$link = ldap_connect_and_bind($host, $port, $user, $passwd, $protocol_version); 15insert_dummy_data($link, $base); 16$result = ldap_search($link, "$base", "(objectclass=person)"); 17var_dump(ldap_count_entries($link, $result)); 18?> 19--CLEAN-- 20<?php 21include "connect.inc"; 22 23$link = ldap_connect_and_bind($host, $port, $user, $passwd, $protocol_version); 24remove_dummy_data($link, $base); 25?> 26--EXPECT-- 27int(3) 28