X-Git-Url: https://git.tokkee.org/?a=blobdiff_plain;f=include%2Ffunctions.inc;h=46a0e53e9ddd51036441153a199723d2d01d374f;hb=f147ecff6f7fe1daeaeff11bbf816e5a002dd784;hp=2262718feee29e28c1302b785ac85c3c0d73e246;hpb=c5feaf357cde87e231884b486c772d90d627444c;p=gosa.git diff --git a/include/functions.inc b/include/functions.inc index 2262718fe..46a0e53e9 100644 --- a/include/functions.inc +++ b/include/functions.inc @@ -367,8 +367,8 @@ function ldap_login_user ($username, $password) function ldap_expired_account($config, $userdn, $username) { - $this->config= $config; - $ldap= $this->config->get_ldap_link(); + //$this->config= $config; + $ldap= $config->get_ldap_link(); $ldap->cat($userdn); $attrs= $ldap->fetch(); @@ -909,7 +909,7 @@ function get_base_from_people($dn) { global $config; - $pattern= "/^[^,]+,".preg_quote(get_people_ou())."/"; + $pattern= "/^[^,]+,".preg_quote(get_people_ou())."/i"; $base= preg_replace($pattern, '', $dn); /* Set to base, if we're not on a correct subtree */ @@ -1194,7 +1194,7 @@ function get_printer_list($cups_server) $ar = false; exec("lpstat -p", $ar); foreach($ar as $val){ - list($dummy, $printer, $rest)= split(' ', $val, 3); + @list($dummy, $printer, $rest)= split(' ', $val, 3); if (preg_match('/^[^@]+$/', $printer)){ $res[$printer]= "$printer"; } @@ -1274,10 +1274,10 @@ function dn2base($dn) global $config; if (get_people_ou() != ""){ - $dn= preg_replace('/,'.get_people_ou().'/' , ',', $dn); + $dn= preg_replace('/,'.get_people_ou().'/i' , ',', $dn); } if (get_groups_ou() != ""){ - $dn= preg_replace('/,'.get_groups_ou().'/' , ',', $dn); + $dn= preg_replace('/,'.get_groups_ou().'/i' , ',', $dn); } $base= preg_replace ('/^[^,]+,/i', '', $dn);