From c0c7ce59ad9a40c96edeeb3163bd5e2be8e9a8a3 Mon Sep 17 00:00:00 2001 From: Jan Dittberner Date: Fri, 23 Nov 2007 18:48:56 +0000 Subject: [PATCH] make group autocompletion work again fixes #5 --- admin/getgroups.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/admin/getgroups.php b/admin/getgroups.php index f32cbfd..c7bce58 100644 --- a/admin/getgroups.php +++ b/admin/getgroups.php @@ -56,12 +56,13 @@ function getGroups($part) { $last_string = trim(array_pop($array)); $retval = array(); if ($last_string != '') { + $prefix = count($array) ? implode(",", $array) . ", ": ''; $groups = file($GLOBALS['davconfig']['group.file']); foreach ($groups as $line) { list($group, $users) = explode(":", $line); $group = trim($group); if (stripos($group, $last_string) === 0) { - array_push($retval, $group); + $retval[$prefix . $group] = $group; } } }