MDL-27464 continuation link sometimes links off-site

This code was manually merged from MOODLE_19_STABLE, credit goes to Matt Meisberger.
This commit is contained in:
Petr Skoda
2011-07-23 13:28:43 +02:00
parent 6884b598f3
commit c8d3345cd3
+6
View File
@@ -501,6 +501,12 @@ function get_exception_info($ex) {
}
}
// when printing an error the continue button should never link offsite
if (stripos($link, $CFG->wwwroot) === false &&
stripos($link, $CFG->httpswwwroot) === false) {
$link = $CFG->wwwroot.'/';
}
$info = new stdClass();
$info->message = $message;
$info->errorcode = $errorcode;