MDL-29862 incorrect wwwroot must be detected before session start

This commit is contained in:
Petr Skoda
2011-10-21 09:52:18 +02:00
parent 3a81b37617
commit d21149699c
2 changed files with 9 additions and 5 deletions
+3 -4
View File
@@ -675,6 +675,9 @@ if (isset($_SERVER['PHP_SELF'])) {
unset($phppos);
}
// initialise ME's - this must be done BEFORE starting of session!
initialise_fullme();
// init session prevention flag - this is defined on pages that do not want session
if (CLI_SCRIPT) {
// no sessions in CLI scripts possible
@@ -697,10 +700,6 @@ session_get_instance();
$SESSION = &$_SESSION['SESSION'];
$USER = &$_SESSION['USER'];
// initialise ME's
// This must presently come AFTER $USER has been set up.
initialise_fullme();
// Late profiling, only happening if early one wasn't started
if (!empty($CFG->profilingenabled)) {
require_once($CFG->libdir . '/xhprof/xhprof_moodle.php');