Forum Moderators: open
So :
typed: t
match: taller, tasty, teletubby, tuba
typed: ta
match: taller, tasty
typed: tas
match: tasty, etc. If you can locate a basic AJAX script that sends a query to a db, you should be able to modify it pretty easily.
[edited by: StupidScript at 5:55 pm (utc) on Jan. 30, 2007]
--with-ldap.)
Heres part of the code:
// Create the DN
$dn = "OU=user,OU=accounts,OU=UK,OU=regions,DC=DOMAIN,DC=com";
$dn2 = "OU=user,OU=accounts,OU=US,DC=DOMAIN,DC=com";
// Specify only those parameters we're interested in displaying
$attrs = array("displayname","mail","samaccountname","telephonenumber","givenname");
// Create the filter from the search parameters
$filter = "(¦(givenName=".$_GET['q']."*) (sn=".$_GET['q']."*) (samaccountname=".$_GET['q']."*) (telephonenumber=".$_GET['q']."*))";
$search = ldap_search($ad, $dn, $dn2, $filter, $attrs)
or die ("<span class='LSstyle_noresults'><strong>Sorry - could not connect to AD</strong></span>");
$entries = ldap_get_entries($ad, $search);
if ($entries["count"] > 0) {