title: how can I get ALL LDAP entries?
body: <p>I know how to LDAP bind for authentication which uses search but what can I do if I want ALL of the entries of Full Names...So how can I get the Full names or emails of ALL the people??</p>
  
  <p>Below I use LDAP bind for authentication and I can search for one person but what if I want them all?</p>
  
  <pre><code>&lt;?php
  
  // using ldap bind
  $ldaprdn  = 'uname';     // ldap rdn or dn
  $ldappass = 'password';  // associated password
  
  // connect to ldap server
  $ldapconn = ldap_connect("ldap.example.com")
      or die("Could not connect to LDAP server.");
  
  if ($ldapconn) {
  
      // binding to ldap server
      $ldapbind = ldap_bind($ldapconn, $ldaprdn, $ldappass);
  
      // verify binding
      if ($ldapbind) {
          echo "LDAP bind successful...";
      } else {
          echo "LDAP bind failed...";
      }
  
  }
  
  ?&gt;
  </code></pre>
  
  <p>This is some MySQL code I have that populates an html list:</p>
  
  <pre><code>&lt;ol&gt;     
  
  &lt;?php
  mysql_connect("kool", "ohjoa", "sampa") or die(mysql_error());
  mysql_select_db("DBtest") or die(mysql_error());
  
  $query = "SELECT * FROM EditOnCall"; 
  
  $result = mysql_query($query) or die(mysql_error());
  
  
  while($row = mysql_fetch_array($result)){
      echo "&lt;li&gt;".$row['Email']."&lt;/li&gt;";
      echo "&lt;br /&gt;";
  }
  
  
  ?&gt;
  
  &lt;/ol&gt;
  </code></pre>
  
  <p>Now this displays a html list of emails. What I want to do is the same thing with LDAP except display the Full Name of all the ldap users in a directory...MY LDAP only has 200 people in it so its not too big.</p>
  
  <p>Any Ideas?</p>