Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/matomo-org/matomo.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormattpiwik <matthieu.aubry@gmail.com>2012-02-25 10:45:24 +0400
committermattpiwik <matthieu.aubry@gmail.com>2012-02-25 10:45:24 +0400
commit9f67d09500715cad5a3a73586c45763edcab31cd (patch)
treebdf1334f25e259d354f1fa82d60f4768e34d4d67 /core/ReportRenderer/Html.php
parent1453b2039458601ee22bbdf5e848114112e89c25 (diff)
Fix bug that when a report name contains double quote, the download link works but does include the end of the filename.html
git-svn-id: http://dev.piwik.org/svn/trunk@5909 59fd770c-687e-43c8-a1e3-f5a4ff64c105
Diffstat (limited to 'core/ReportRenderer/Html.php')
-rw-r--r--core/ReportRenderer/Html.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/core/ReportRenderer/Html.php b/core/ReportRenderer/Html.php
index a3dec2d036..925ee3b799 100644
--- a/core/ReportRenderer/Html.php
+++ b/core/ReportRenderer/Html.php
@@ -60,7 +60,7 @@ class Piwik_ReportRenderer_Html extends Piwik_ReportRenderer
Piwik::overrideCacheControlHeaders();
header('Content-Description: File Transfer');
header('Content-Type: text/html');
- header('Content-Disposition: attachment; filename="'.basename($filename).'";');
+ header('Content-Disposition: attachment; filename="'.str_replace('"', '\'', basename($filename)).'";');
header('Content-Length: '.strlen($this->rendering));
echo $this->rendering;
}