summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 1d40713)
raw | patch | inline | side by side (parent: 1d40713)
author | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Thu, 1 Sep 2005 05:57:39 +0000 (05:57 +0000) | ||
committer | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Thu, 1 Sep 2005 05:57:39 +0000 (05:57 +0000) |
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@1276 594d385d-05f5-0310-b6e9-bd551577e9d8
include/functions.inc | patch | blob | history |
diff --git a/include/functions.inc b/include/functions.inc
index 3c85199dc2281f00a58e67aa39be85828e18225c..26ae481b5911bbc1be64be92f6474ad366c4ba4d 100644 (file)
--- a/include/functions.inc
+++ b/include/functions.inc
specified in $dn */
$deps = array_flip($_SESSION['config']->idepartments);
- $dn= $deps[$dn];
-
- $tmp = split (",", $dn);
-
-// $dep= preg_replace("%^.*/([^/]+)$%", "\\1", $tmp[0]);
- $dep = preg_replace("/^.*=/","",$tmp[0]);
+ if(isset($deps[$dn])){
+ $dn= $deps[$dn];
+ $tmp = split (",", $dn);
+ $dep = preg_replace("/^.*=/","",$tmp[0]);
+ }else{
+ $tmp = split (",", $dn);
+ $dep= preg_replace("%^.*/([^/]+)$%", "\\1", $tmp[0]);
+ }
/* Return and remove accidently trailing slashes */
$tmp = rtrim($dep, "/");