From 298481260e4d5cb7ff4ccd21b33cc2976c277f14 Mon Sep 17 00:00:00 2001 From: vyshane Date: Mon, 22 Jan 2007 06:57:40 +0000 Subject: [PATCH] Fixed MDL-8183. --- group/index.php | 6 +-- group/lib/clientlib.js | 83 +++++++++++++++++++++++++----------------- 2 files changed, 52 insertions(+), 37 deletions(-) diff --git a/group/index.php b/group/index.php index 336740dc99..7c1c2d1ec7 100644 --- a/group/index.php +++ b/group/index.php @@ -143,9 +143,9 @@ if ($success) {

- $name\n"; + echo "\n"; $count++; } } diff --git a/group/lib/clientlib.js b/group/lib/clientlib.js index 66689840b0..8e20f0bc1b 100644 --- a/group/lib/clientlib.js +++ b/group/lib/clientlib.js @@ -27,32 +27,33 @@ function UpdatableGroupsCombo(wwwRoot, courseId) { } } - if (groupsComboEl) { - // Clear the groups combo box. - while (groupsComboEl.firstChild) { - groupsComboEl.removeChild(groupsComboEl.firstChild); + if (groupsComboEl && o.responseText) { + //var groups = eval("("+o.responseText+")"); + var groups = eval(o.responseText); + + // Populate the groups combo box. + for (var i=0; i