From: hickert Date: Fri, 31 Aug 2007 05:55:25 +0000 (+0000) Subject: Updated department listing - preg_match wasn't escaped correctly X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=60faf8f243c64d9ce59c35b8b2ccf4c6ca28396d;p=gosa.git Updated department listing - preg_match wasn't escaped correctly git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@7172 594d385d-05f5-0310-b6e9-bd551577e9d8 --- diff --git a/plugins/admin/departments/class_divListDepartment.inc b/plugins/admin/departments/class_divListDepartment.inc index 97a913380..6d6595ace 100755 --- a/plugins/admin/departments/class_divListDepartment.inc +++ b/plugins/admin/departments/class_divListDepartment.inc @@ -173,10 +173,13 @@ class divListDepartment extends MultiSelectWindow $this->config->departments[trim($key)]=""; } + /* check if this department contains sub-departments + Display different image in this case + */ $non_empty=""; - $keys= str_replace("/","\/",$key); + $nkey= normalizePreg($key); foreach($this->config->departments as $keyd=>$vald ){ - if(preg_match("/".$keys."\/.*/",$keyd)){ + if(preg_match('/$nkey\/.*/',$keyd)){ $non_empty="full"; } }