Finally the *correct* fix for the looping problem. Thanks to Penny (Merged from MOODLE_15_STABLE)

This commit is contained in:
patrickslee
2005-09-07 04:23:37 +00:00
parent 9d866ae0f1
commit dd875f1aa2
2 changed files with 6 additions and 4 deletions
+5
View File
@@ -314,6 +314,11 @@ $CFG->httpswwwroot = $CFG->wwwroot;
} else {
$_COOKIE['MoodleSessionTest'.$CFG->sessioncookie] = 'error!!';
}
} else {
if (empty($_COOKIE['MoodleSessionTest'.$CFG->sessioncookie])) {
setcookie('MoodleSessionTest'.$CFG->sessioncookie, $_SESSION['SESSION']->session_test, 0, '/');
$_COOKIE['MoodleSessionTest'.$CFG->sessioncookie] = $_SESSION['SESSION']->session_test;
}
}
if (! isset($_SESSION['USER'])) {
$_SESSION['USER'] = new object;