From: cajus Date: Mon, 3 Nov 2008 08:59:57 +0000 (+0000) Subject: More preg_replace replacements X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=da1b35b1343f11e46bed8f993c57d1f779e0d1f2;p=gosa.git More preg_replace replacements git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@12864 594d385d-05f5-0310-b6e9-bd551577e9d8 --- diff --git a/gosa-core/include/class_acl.inc b/gosa-core/include/class_acl.inc index f0b2af9ce..ad4c41fe3 100644 --- a/gosa-core/include/class_acl.inc +++ b/gosa-core/include/class_acl.inc @@ -140,7 +140,8 @@ class acl extends plugin foreach ($this->parent->by_object as $key => $obj){ $oc= array_merge($oc, $obj->objectclasses); if(isset($obj->acl_category)){ - $cats[preg_replace("/\//","",$obj->acl_category)] = preg_replace("/\//","",$obj->acl_category); + $tmp= str_replace("/","",$obj->acl_category); + $cats[$tmp] = $tmp; } } if (in_array_ics('organizationalUnit', $oc)){ @@ -267,8 +268,7 @@ class acl extends plugin continue; } - /* Only handle posts, if we allowed to modify ACLs - */ + /* Only handle posts, if we allowed to modify ACLs */ if(!$this->acl_is_writeable("")){ continue; } @@ -720,20 +720,21 @@ class acl extends plugin } /* Object header */ + $tname= preg_replace("/[^a-z0-9]/i","_",$name); if(session::get('js')) { if(isset($_SERVER['HTTP_USER_AGENT']) && preg_match("/gecko/i",$_SERVER['HTTP_USER_AGENT'])) { $display.= "\n". "\n ". "\n ". "\n ". + "\n ". "\n "; } else if (isset($_SERVER['HTTP_USER_AGENT']) && preg_match("/ie/i",$_SERVER['HTTP_USER_AGENT'])) { $display.= "\n
"._("Object").": $name". - "\n
". "\n ". "\n ". "\n ". + "\n ". "\n "; } else { $display.= "\n
"._("Object").": $name". - "\n
". @@ -780,14 +781,14 @@ class acl extends plugin # asort($splist); if(session::get('js')) { if(isset($_SERVER['HTTP_USER_AGENT']) && preg_match("/gecko/i",$_SERVER['HTTP_USER_AGENT'])) { - $display.= "\n ". + $display.= "\n ". "\n
". - "\n