From 75feff115439097c987dd9df2a67ad6f7d6bcd52 Mon Sep 17 00:00:00 2001 From: gbateson Date: Fri, 17 Apr 2009 01:43:51 +0000 Subject: [PATCH] MDL-18883: fix setting of absolute urls for images in subfolders of course files --- question/format/hotpot/format.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/question/format/hotpot/format.php b/question/format/hotpot/format.php index e2b4c18b893..5af7c20f441 100644 --- a/question/format/hotpot/format.php +++ b/question/format/hotpot/format.php @@ -47,7 +47,9 @@ class qformat_hotpot extends qformat_default { // get import file name global $params; - if (isset($params) && !empty($params->choosefile)) { + if (! empty($this->realfilename)) { + $filename = $this->realfilename; + } else if (isset($params) && !empty($params->choosefile)) { // course file (Moodle >=1.6+) $filename = $params->choosefile; } else {