MDL-37942 Images with non-alphanumeric chars in file name won't export

This commit is contained in:
Jason Platts
2013-04-22 12:44:16 +01:00
committed by Dan Poltawski
parent 42f64a01c7
commit ced8b30bd5
+1 -1
View File
@@ -1260,7 +1260,7 @@ function portfolio_rewrite_pluginfile_url_callback($contextid, $component, $file
$filename = array_pop($bits);
$filepath = implode('/', $bits);
}
if (!$file = $fs->get_file($contextid, $component, $filearea, $itemid, $filepath, $filename)) {
if (!$file = $fs->get_file($contextid, $component, $filearea, $itemid, $filepath, urldecode($filename))) {
debugging("Couldn't find a file from the embedded path info context $contextid component $component filearea $filearea itemid $itemid filepath $filepath name $filename");
return $matches;
}