From 1154541d65c5ee61825417e93c35074f54efb1b9 Mon Sep 17 00:00:00 2001 From: Lukas Winkler Date: Sat, 10 Feb 2018 18:10:04 +0100 Subject: [PATCH] make privacy policy URL configurable --- src/config/config.example.php | 7 ++++++- src/public/index.php | 1 + src/templates/layout.twig | 4 +++- 3 files changed, 10 insertions(+), 2 deletions(-) diff --git a/src/config/config.example.php b/src/config/config.example.php index 595d540..f06bbf2 100644 --- a/src/config/config.example.php +++ b/src/config/config.example.php @@ -54,4 +54,9 @@ define("PAGINATION_PADDING", 5); /** * used in sitemap (without trailing slash) */ -define("BASE_DOMAIN", "https://issues.matomo.org"); \ No newline at end of file +define("BASE_DOMAIN", "https://issues.matomo.org"); + +/** + * URL to privacy policy (linked in footer) + */ +define("PRIVACY_POLICY_URL", "https://matomo.org/privacy-policy/"); \ No newline at end of file diff --git a/src/public/index.php b/src/public/index.php index ec0a772..d9498cf 100644 --- a/src/public/index.php +++ b/src/public/index.php @@ -41,6 +41,7 @@ $container['view'] = function ($container) { $view->getEnvironment()->addGlobal('githubRepository', GITHUB_REPOSITORY); $view->getEnvironment()->addGlobal('matomoURL', MATOMO_URL); $view->getEnvironment()->addGlobal('matomoID', MATOMO_ID); + $view->getEnvironment()->addGlobal('privacyPolicyURL', PRIVACY_POLICY_URL); return $view; }; diff --git a/src/templates/layout.twig b/src/templates/layout.twig index 8307088..2dc8a4b 100644 --- a/src/templates/layout.twig +++ b/src/templates/layout.twig @@ -22,9 +22,11 @@
Powered by GitHub Issue Mirror
+ {% if privacyPolicyURL %}
- Privacy Policy + Privacy Policy
+ {% endif %}