From: hickert Date: Mon, 26 Apr 2010 13:06:36 +0000 (+0000) Subject: Updated baseSelector - just testing X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=91d21d3282a7f9245ec7d7f02dbb88c955d4d732;p=gosa.git Updated baseSelector - just testing git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@17845 594d385d-05f5-0310-b6e9-bd551577e9d8 --- diff --git a/gosa-core/include/class_baseSelector.inc b/gosa-core/include/class_baseSelector.inc index 68dd3ca03..b11c83649 100644 --- a/gosa-core/include/class_baseSelector.inc +++ b/gosa-core/include/class_baseSelector.inc @@ -57,6 +57,7 @@ class baseSelector { function setBase($base) { + $base = LDAP::fix($base); if (isset($this->pathMapping[$base])) { $this->base= $base; $this->update(true); @@ -91,7 +92,7 @@ class baseSelector { $elements= explode(',', substr($base, 0, strlen($base) - strlen($config->current['BASE']))); $elements= array_reverse($elements, true); - $this->pathMapping[$base]= $base == $config->current['BASE']? '/' : ldap::fix(preg_replace('/(^|,)[a-z0-9]+=/i', '/', implode(',', $elements))); + $this->pathMapping[LDAP::fix($base)]= $base == $config->current['BASE']? '/' : ldap::fix(preg_replace('/(^|,)[a-z0-9]+=/i', '/', implode(',', $elements))); } // Save bases to session for autocompletion @@ -188,8 +189,8 @@ class baseSelector { $link= "onclick=\"\$('bs_rebase_".$this->pid."').value='".base64_encode($base)."';$('submit_tree_base_".$this->pid."').click();\""; $this->tree.= "
  • ". image($config->department_info[$base]['img'])." ". - $this->gennonbreaks($config->department_info[$base]['name']). - ($config->department_info[$base]['description']==''?'':' ['.$this->gennonbreaks($config->department_info[$base]['description']).']'). + ($this->gennonbreaks($config->department_info[LDAP::fix($base)]['name'])). + ($config->department_info[LDAP::fix($base)]['description']==''?'':' ['.$this->gennonbreaks($config->department_info[LDAP::fix($base)]['description']).']'). ""; $last_indent= $indent; diff --git a/gosa-core/include/class_config.inc b/gosa-core/include/class_config.inc index 07e915256..f89a32b1b 100644 --- a/gosa-core/include/class_config.inc +++ b/gosa-core/include/class_config.inc @@ -756,7 +756,7 @@ class config { $dn= $ldap->getDN(); $this->tdepartments[$dn]= ""; - $this->department_info[$dn]= array("img" => $type_data['IMG'], + $this->department_info[LDAP::fix($dn)]= array("img" => $type_data['IMG'], "description" => isset($attrs['description'][0])?$attrs['description'][0]:"", "name" => $attrs[$type_data['ATTR']][0]);