You are here

function LDAPInterface::connect in LDAP integration 6

Same name and namespace in other branches
  1. 5.2 ldap_integration/LDAPInterface.php \LDAPInterface::connect()
  2. 5 ldap_integration/LDAPInterface.php \LDAPInterface::connect()

File

includes/LDAPInterface.inc, line 135
LDAPInterface class definition.

Class

LDAPInterface
@file LDAPInterface class definition.

Code

function connect($dn = '', $pass = '') {
  $ret = FALSE;

  // http://drupal.org/node/164049
  // If a connection already exists, it should be terminated
  $this
    ->disconnect();
  if ($this
    ->connectAndBind($dn, $pass)) {
    $ret = TRUE;
  }
  return $ret;
}