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/Installation/Installation.php')
-rw-r--r--plugins/Installation/Installation.php20
1 files changed, 19 insertions, 1 deletions
diff --git a/plugins/Installation/Installation.php b/plugins/Installation/Installation.php
index 46e6122f6a..023723c3b3 100644
--- a/plugins/Installation/Installation.php
+++ b/plugins/Installation/Installation.php
@@ -105,7 +105,7 @@ class Installation extends \Piwik\Plugin
if ($this->isAllowedAction($action)) {
echo FrontController::getInstance()->dispatch('Installation', $action, array($message));
} else {
- Piwik::exitWithErrorMessage(Piwik::translate('Installation_NoConfigFound'));
+ Piwik::exitWithErrorMessage($this->getMessageToInviteUserToInstallPiwik($message));
}
exit;
@@ -127,4 +127,22 @@ class Installation extends \Piwik\Plugin
return in_array($action, array_keys($controller->getInstallationSteps()))
|| $isActionWhiteListed;
}
+
+ /**
+ * @param $message
+ * @return string
+ */
+ private function getMessageToInviteUserToInstallPiwik($message)
+ {
+ $messageWhenPiwikSeemsNotInstalled =
+ $message .
+ "\n<br/>" .
+ Piwik::translate('Installation_NoConfigFileFound') .
+ "<br/><b>ยป " .
+ Piwik::translate('Installation_YouMayInstallPiwikNow', array("<a href='index.php'>", "</a></b>")) .
+ "<br/><small>" .
+ Piwik::translate('Installation_IfPiwikInstalledBeforeTablesCanBeKept') .
+ "</small>";
+ return $messageWhenPiwikSeemsNotInstalled;
+ }
}