<?php include_once $_SERVER['DOCUMENT_ROOT'] . '/include/shared-manual.inc'; $TOC = array(); $TOC_DEPRECATED = array(); $PARENTS = array(); include_once dirname(__FILE__) ."/toc/book.ldap.inc"; $setup = array ( 'home' => array ( 0 => 'index.php', 1 => 'PHP Manual', ), 'head' => array ( 0 => 'UTF-8', 1 => 'en', ), 'this' => array ( 0 => 'ldap.using.php', 1 => 'Using the PHP LDAP calls', ), 'up' => array ( 0 => 'book.ldap.php', 1 => 'LDAP', ), 'prev' => array ( 0 => 'ldap.constants.php', 1 => 'Predefined Constants', ), 'next' => array ( 0 => 'ldap.controls.php', 1 => 'LDAP controls', ), 'alternatives' => array ( ), 'source' => array ( 'lang' => 'en', 'path' => 'reference/ldap/using.xml', ), 'history' => array ( ), ); $setup["toc"] = $TOC; $setup["toc_deprecated"] = $TOC_DEPRECATED; $setup["parents"] = $PARENTS; manual_setup($setup); contributors($setup); ?> <div id="ldap.using" class="chapter"> <h1 class="title">Using the PHP LDAP calls</h1> <p class="para"> Before you can use the LDAP calls you will need to know... <ul class="itemizedlist"> <li class="listitem"> <p class="para"> The name or address of the directory server you will use </p> </li> <li class="listitem"> <p class="para"> The "base dn" of the server (the part of the world directory that is held on this server, which could be "o=My Company,c=US") </p> </li> <li class="listitem"> <p class="para"> Whether you need a password to access the server (many servers will provide read access for an "anonymous bind" but require a password for anything else) </p> </li> </ul> </p> <p class="para"> The typical sequence of LDAP calls you will make in an application will follow this pattern: <pre class="literallayout"> ldap_connect() // establish connection to server | ldap_bind() // anonymous or authenticated "login" | do something like search or update the directory and display the results | ldap_close() // "logout" </pre> </p> </div> <?php manual_footer($setup); ?>