diff --git a/lib/weblib.php b/lib/weblib.php index 0edaf2324fe..80352f03bc8 100644 --- a/lib/weblib.php +++ b/lib/weblib.php @@ -777,7 +777,7 @@ function print_file_picture($path, $courseid=0, $height="", $width="", $link="") if ($CFG->slasharguments) { // Use this method if possible for better caching echo "$CFG->wwwroot/file.php/$courseid/$path"; } else { - echo "$CFG->wwwroot/file.php?file=$courseid/$path"; + echo "$CFG->wwwroot/file.php?file=/$courseid/$path"; } echo "\">"; } else {