MDL-15800 fixed undefined wwwroot problem - credit goes to Charlie Owen

This commit is contained in:
skodak
2008-10-07 22:04:51 +00:00
parent 1afb6de73e
commit 536db61cae
+6 -6
View File
@@ -57,13 +57,13 @@ function ajax_get_lib($libname) {
'ajaxcourse' => '/lib/ajax/ajaxcourse.js'
);
if (!empty($HTTPSPAGEREQUIRED)) {
$wwwroot = $CFG->httpswwwroot;
} else {
$wwwroot = $CFG->wwwroot;
}
if (array_key_exists($libname, $translatelist)) {
if (!empty($HTTPSPAGEREQUIRED)) {
$wwwroot = $CFG->httpswwwroot;
}
else {
$wwwroot = $CFG->wwwroot;
}
$libpath = $wwwroot . $translatelist[$libname];
} else {
$libpath = $libname;