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:
Diffstat (limited to 'plugins/ScheduledReports')
-rw-r--r--plugins/ScheduledReports/ScheduledReports.php5
1 files changed, 4 insertions, 1 deletions
diff --git a/plugins/ScheduledReports/ScheduledReports.php b/plugins/ScheduledReports/ScheduledReports.php
index 2aebe4daaa..edb0a3e691 100644
--- a/plugins/ScheduledReports/ScheduledReports.php
+++ b/plugins/ScheduledReports/ScheduledReports.php
@@ -9,6 +9,7 @@
namespace Piwik\Plugins\ScheduledReports;
use Exception;
+use Piwik\Common;
use Piwik\Config;
use Piwik\Container\StaticContainer;
use Piwik\Log;
@@ -365,7 +366,9 @@ class ScheduledReports extends \Piwik\Plugin
// add unsubscribe links to content
if ($htmlContent) {
$link = SettingsPiwik::getPiwikUrl() . 'index.php?module=ScheduledReports&action=unsubscribe&token=' . $tokens[$email];
- $mail->setBodyHtml($htmlContent . '<br /><br /><hr /><br />'.Piwik::translate('ScheduledReports_UnsubscribeFooter', [' <a href="' . $link . '">' . Piwik::translate('ScheduledReports_Unsubscribe') . '</a>']));
+ $bodyContent = str_replace(ReportRenderer\Html::UNSUBSCRIBE_LINK_PLACEHOLDER, Common::sanitizeInputValue($link), $htmlContent);
+
+ $mail->setBodyHtml($bodyContent);
}
if ($textContent) {