From: David Mudrak Date: Mon, 4 Jan 2010 18:22:58 +0000 (+0000) Subject: workshop: fixed link to the attachment in a folder X-Git-Url: http://git.mjollnir.org/gw?a=commitdiff_plain;h=aa6610f31bc686dc08515832803a5df36ac9ffe0;p=moodle.git workshop: fixed link to the attachment in a folder --- diff --git a/mod/workshop/renderer.php b/mod/workshop/renderer.php index d282336206..43be8cf148 100644 --- a/mod/workshop/renderer.php +++ b/mod/workshop/renderer.php @@ -262,9 +262,10 @@ class moodle_mod_workshop_renderer extends moodle_renderer_base { continue; } + $filepath = $file->get_filepath(); $filename = $file->get_filename(); $fileurl = file_encode_url($CFG->wwwroot . '/pluginfile.php', - '/' . $ctx->id . '/workshop_submission_attachment/' . $submission->id . '/' . $filename, true); + '/' . $ctx->id . '/workshop_submission_attachment/' . $submission->id . $filepath . $filename, true); $type = $file->get_mimetype(); $type = mimeinfo_from_type("type", $type); $icon = new html_image();