adding proper checks that the requested help file exists SC#292; merged from MOODLE_16_STABLE

This commit is contained in:
skodak
2006-08-14 20:08:52 +00:00
parent cfef9e55d0
commit 508d4a0d14
+2 -2
View File
@@ -56,9 +56,9 @@
}
}
if (file_exists($filepath)) {
if (file_exists($filepath) and is_file($filepath) and is_readable($filepath)) {
$helpfound = true;
include($filepath); // The actual helpfile
@include($filepath); // The actual helpfile
if ($module == 'moodle' and ($file == 'index.html' or $file == 'mods.html')) {
// include file for each module