mirror of
https://github.com/moodle/moodle.git
synced 2025-01-17 21:49:15 +01:00
MDL-28701 Fixed broken $CFG->tempdir default and added $CFG->cachedir
This commit is contained in:
parent
7aa06e6ded
commit
383d388411
@ -37,6 +37,7 @@
|
||||
* - $CFG->dirroot - Path to moodle's library folder on server's filesystem.
|
||||
* - $CFG->libdir - Path to moodle's library folder on server's filesystem.
|
||||
* - $CFG->tempdir - Path to moodle's temp file directory on server's filesystem.
|
||||
* - $CFG->cachedir - Path to moodle's cache directory on server's filesystem.
|
||||
*
|
||||
* @global object $CFG
|
||||
* @name $CFG
|
||||
@ -97,9 +98,14 @@ if (!isset($CFG->admin)) { // Just in case it isn't defined in config.php
|
||||
// Set up some paths.
|
||||
$CFG->libdir = $CFG->dirroot .'/lib';
|
||||
|
||||
// Allow overriding of tempdir but be backwards compatible with tempdir
|
||||
// Allow overriding of tempdir but be backwards compatible
|
||||
if (!isset($CFG->tempdir)) {
|
||||
$CFG->tempdir = "$CFG->tempdir";
|
||||
$CFG->tempdir = "$CFG->dataroot/temp";
|
||||
}
|
||||
|
||||
// Allow overriding of cachedir but be backwards compatible
|
||||
if (!isset($CFG->cachedir)) {
|
||||
$CFG->cachedir = "$CFG->dataroot/cache";
|
||||
}
|
||||
|
||||
// The current directory in PHP version 4.3.0 and above isn't necessarily the
|
||||
|
Loading…
x
Reference in New Issue
Block a user