pql_units.inc

Sabbe Guillaume <[email protected]> Mon, 17 Apr 2006 22:19:45 +0200
Newsgroups gmane.mail.qmail.ldap.phpqladmin
Message-ID <[email protected]>
hello, I'm using the latest stable *_REL_2_2_6_
*My ldap tree is organized with ou branchs
dc=mydomain,dc=be
|_ ou=mydomain.be,dc=mydomain,dc=be
|_ ou = otherdomain.be,dc=mydomain,dc=be

So phpQLAdmin is configured with "Reference domains with: ou"
I have in the left menu :
Warning: array_merge() [function.array-merge]: Argument #2 is not an 
array in /data/www/localhost/htdocsssl/phpQLAdmin/include/pql_units.inc 
on line 24

Here a part of pql_units.inc :

        if(pql_get_define("PQL_CONF_REFERENCE_DOMAINS_WITH", $rootdn) == 
"dc")
          // Look for sub-domains below this domain branch.
          $subd = pql_get_dn($linkid, $dn, 'objectclass=domain', 
'ONELEVEL');

        // Either we couldn't find any sub-domains below the domain 
branch, OR
        // we have the database layout organized with organization.
        // -> Either way, look for organizational unit below the DN as well.
        $ocs = pql_get_dn($linkid, $dn, 
'objectclass=organizationalUnit', 'ONELEVEL');

        // Join the two values
        $info = array_merge($subd, $ocs);

Here is the problem, pql_get_define("PQL_CONF_REFERENCE_DOMAINS_WITH", 
$rootdn) == "dc" is false
so $subd is null and array_merge fails ..
I commented out         $info = array_merge($subd, $ocs); and added 
$info = $ocs;
But I'm sure you have a better solution .

Thanks