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:
authorMatthieu Napoli <matthieu@mnapoli.fr>2015-04-09 04:47:12 +0300
committerMatthieu Napoli <matthieu@mnapoli.fr>2015-04-16 05:45:12 +0300
commit268e5c995b5a38c1f0b79c26dc9e7af5142c23e7 (patch)
tree42f1f1ce56b0fb9d4466852fbe3e52462ea471a7 /core/FrontController.php
parent5bd47b2f7c202206d0decb18da64acf91bf72d13 (diff)
#7620 Redesign of the maintenance mode
Diffstat (limited to 'core/FrontController.php')
-rw-r--r--core/FrontController.php19
1 files changed, 2 insertions, 17 deletions
diff --git a/core/FrontController.php b/core/FrontController.php
index e697985f1e..d72cfe40b7 100644
--- a/core/FrontController.php
+++ b/core/FrontController.php
@@ -415,23 +415,8 @@ class FrontController extends Singleton
if (Config::getInstance()->General['maintenance_mode'] == 1
&& !Common::isPhpCliMode()
) {
- $format = Common::getRequestVar('format', '');
-
- $message = "Piwik is in scheduled maintenance. Please come back later."
- . " The administrator can disable maintenance by editing the file piwik/config/config.ini.php and removing the following: "
- . " maintenance_mode=1 ";
- if (Config::getInstance()->Tracker['record_statistics'] == 0) {
- $message .= ' and record_statistics=0';
- }
-
- $exception = new Exception($message);
- // extend explain how to re-enable
- // show error message when record stats = 0
- if (empty($format)) {
- throw $exception;
- }
- $response = new ResponseBuilder($format);
- echo $response->getResponseException($exception);
+ Common::sendResponseCode(503);
+ echo file_get_contents(PIWIK_INCLUDE_PATH . '/plugins/Morpheus/templates/maintenance.tpl');
exit;
}
}