diff options
-rw-r--r-- | core/FrontController.php | 12 | ||||
-rw-r--r-- | plugins/Morpheus/templates/maintenance.tpl | 2 |
2 files changed, 13 insertions, 1 deletions
diff --git a/core/FrontController.php b/core/FrontController.php index 38a44db5da..975e6d9f45 100644 --- a/core/FrontController.php +++ b/core/FrontController.php @@ -446,10 +446,22 @@ class FrontController extends Singleton } catch (Exception $ex) { } + $recordStatistics = Config::getInstance()->Tracker['record_statistics']; + $trackMessage = ''; + + if ($recordStatistics) { + $trackMessage = 'Your analytics data will continue to be tracked as normal.'; + } else { + $trackMessage = 'While the maintenance mode is active, data tracking is disabled.'; + } + $page = file_get_contents(PIWIK_INCLUDE_PATH . '/plugins/Morpheus/templates/maintenance.tpl'); $page = str_replace('%logoUrl%', $logoUrl, $page); $page = str_replace('%faviconUrl%', $faviconUrl, $page); $page = str_replace('%piwikTitle%', Piwik::getRandomTitle(), $page); + + $page = str_replace('%trackMessage%', $trackMessage, $page); + echo $page; exit; } diff --git a/plugins/Morpheus/templates/maintenance.tpl b/plugins/Morpheus/templates/maintenance.tpl index 9d2cccab8f..edc16e32ad 100644 --- a/plugins/Morpheus/templates/maintenance.tpl +++ b/plugins/Morpheus/templates/maintenance.tpl @@ -23,7 +23,7 @@ <div class="content"> <p> - We will be back up and running again soon, so please try again later. Your analytics data will continue to be tracked as normal. Thank you for your patience. + We will be back up and running again soon, so please try again later. %trackMessage% Thank you for your patience. </p> </div> |