From f1b8bcf70a2297f06c03474517e46adc8fb8d140 Mon Sep 17 00:00:00 2001 From: Petr Skoda Date: Mon, 31 May 2010 18:45:23 +0000 Subject: [PATCH] MDL-22630 adding missing path component into file download link --- mod/resource/lib.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/mod/resource/lib.php b/mod/resource/lib.php index 2629fbadb09..ddbec431b05 100644 --- a/mod/resource/lib.php +++ b/mod/resource/lib.php @@ -272,7 +272,7 @@ function resource_get_coursemodule_info($coursemodule) { return NULL; } // do not open any window because it would be left there after download - $path = '/'.$context->id.'/resource_content/'.$resource->revision.$mainfile->get_filename(); + $path = '/'.$context->id.'/resource_content/'.$resource->revision.$mainfile->get_filepath().$mainfile->get_filename(); $fullurl = addslashes_js(file_encode_url($CFG->wwwroot.'/pluginfile.php', $path, true)); // When completion information is enabled for download files, make @@ -309,7 +309,7 @@ function resource_get_file_areas($course, $cm, $context) { } /** - * File browsing support for resource module ontent area. + * File browsing support for resource module content area. * @param object $browser * @param object $areas * @param object $course