From: cajus Date: Thu, 29 Jun 2006 04:38:28 +0000 (+0000) Subject: Worked around issue with broken LDAP X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=22417728672e8b12d0ef56d6bdd54a1fe46c69a5;p=gosa.git Worked around issue with broken LDAP git-svn-id: https://oss.gonicus.de/repositories/gosa/branches/2.5@3972 594d385d-05f5-0310-b6e9-bd551577e9d8 --- diff --git a/include/functions.inc b/include/functions.inc index 2262718fe..557132952 100644 --- a/include/functions.inc +++ b/include/functions.inc @@ -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 */ @@ -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); diff --git a/plugins/addons/ldapmanager/class_csvimport.inc b/plugins/addons/ldapmanager/class_csvimport.inc index 3e3d0fd58..86fee5fc4 100644 --- a/plugins/addons/ldapmanager/class_csvimport.inc +++ b/plugins/addons/ldapmanager/class_csvimport.inc @@ -84,7 +84,7 @@ class csvimport extends plugin while($temp = $ldap->fetch($this->csvinfo['templates'])){ $tempvar ++; - $this->csvinfo['arrtemplates'][$tempvar] = $temp['sn'][0]." - ".$this->config->idepartments[preg_replace("/^[^,]+,".get_people_ou()."/", "", $temp['dn'])]; + $this->csvinfo['arrtemplates'][$tempvar] = $temp['sn'][0]." - ".$this->config->idepartments[preg_replace("/^[^,]+,".get_people_ou()."/i", "", $temp['dn'])]; $this->csvinfo['arrtempls'] [$tempvar]['name'] = $temp['sn'][0]; $this->csvinfo['arrtempls'] [$tempvar]['dn'] = $temp['dn']; }