irm/lib/Config.php
/** Return the LDAP config for the current database, if it exists
     * Returns an associative array containing all of the LDAP config
     * parameters for the database that the currently logged-in user
     * is is using, or false if the database does not do LDAP.
     */
Return the LDAP config for the current database, if it exists
Returns an associative array containing all of the LDAP config
parameters for the database that the currently logged-in user
is is using, or false if the database does not do LDAP.
Return the LDAP config for the current database if it exists Returns an associative array containing all of the LDAP config parameters for the database that the currently logged - in user is is using or false if the database does not do LDAP .
static function LDAP()
    {
        $defaults = array('server' => 'localhost',
                'protocol' => '3',
                'fullnamefield' => 'cn',
                'emailfield' => 'mail',
                'locationfield' => 'roomNumber',
                'phonefield' => 'telephoneField',
                'usernamefield' => 'uid'
                );
        $db = @$_SESSION['_sess_database'];
        $cfg = Config::ReadConfig('ldap');
        if (!$cfg)
        {
            return false;
        }
        if (array_key_exists($db, $cfg))
        {
            $cfg = $cfg[$db];
            foreach ($defaults as $k => $v)
            {
                if (!array_key_exists($k, $cfg))
                {
                    $cfg[$k] = $v;
                }
            }
            return $cfg;
        }
        else
        {
            return false;
        }
    }
static function LDAP ( ) { $ defaults = array ( 'server' => 'localhost' , 'protocol' => '3' , 'fullnamefield' => 'cn' , 'emailfield' => 'mail' , 'locationfield' => 'roomNumber' , 'phonefield' => 'telephoneField' , 'usernamefield' => 'uid' ) ; $ db = @ $ _SESSION [ '_sess_database' ] ; $ cfg = Config :: ReadConfig ( 'ldap' ) ; if ( ! $ cfg ) { return false ; } if ( array_key_exists ( $ db , $ cfg ) ) { $ cfg = $ cfg [ $ db ] ; foreach ( $ defaults as $ k => $ v ) { if ( ! array_key_exists ( $ k , $ cfg ) ) { $ cfg [ $ k ] = $ v ; } } return $ cfg ; } else { return false ; } }
Return the LDAP config for the current database, if it exists
 Returns an associative array containing all of the LDAP config
 parameters for the database that the currently logged-in user
 is is using, or false if the database does not do LDAP.
Return the LDAP config for the current database if it exists Returns an associative array containing all of the LDAP config parameters for the database that the currently logged - in user is is using or false if the database does not do LDAP .