From: moodler Date: Mon, 30 Oct 2006 08:21:51 +0000 (+0000) Subject: Merged AJAX GUI fixes from stable X-Git-Url: http://git.mjollnir.org/gw?a=commitdiff_plain;h=7ca163ba21b78b20a634a4cf0660f097e0bb29ad;p=moodle.git Merged AJAX GUI fixes from stable --- diff --git a/user/edit.html b/user/edit.html index 887b296a7e..6bf6efa940 100644 --- a/user/edit.html +++ b/user/edit.html @@ -202,6 +202,9 @@ if (has_capability('moodle/user:update', get_context_instance(CONTEXT_SYSTEM, SI unset($choices); $choices["0"] = get_string("ajaxno"); $choices["1"] = get_string("ajaxyes"); + if (empty($CFG->enableajax)) { + $user->ajax = 0; + } choose_from_menu ($choices, 'ajax', $user->ajax, '', '', 0, false, empty($CFG->enableajax)) ?> diff --git a/user/edit.php b/user/edit.php index e2e9d1ac88..9185328548 100644 --- a/user/edit.php +++ b/user/edit.php @@ -114,6 +114,10 @@ } else { unset_user_preference('mailcharset', $user->id); } + if (empty($CFG->enableajax)) { + unset($usernew->ajax); + } + $usernew->maildigest = clean_param($usernew->maildigest, PARAM_INT); $usernew->autosubscribe = clean_param($usernew->autosubscribe, PARAM_INT); if (!empty($CFG->htmleditor)) {