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:
authorrobocoder <anthon.pang@gmail.com>2011-08-01 20:06:43 +0400
committerrobocoder <anthon.pang@gmail.com>2011-08-01 20:06:43 +0400
commit09f47e1cf27f2971b02f7033a4e4df0206596175 (patch)
treedd7535d6bbe81e2dda8e33b2aac8be6e60c3c085 /core/View.php
parent86d0aa98b28d1afa2b2cb662d04ae4650bc781c0 (diff)
* fixes #2594 - apply gator's patch
* currentUrlWithoutFilename is redundant; consolidate with piwikUrl git-svn-id: http://dev.piwik.org/svn/trunk@5068 59fd770c-687e-43c8-a1e3-f5a4ff64c105
Diffstat (limited to 'core/View.php')
-rw-r--r--core/View.php12
1 files changed, 11 insertions, 1 deletions
diff --git a/core/View.php b/core/View.php
index 1342f77805..da55f59264 100644
--- a/core/View.php
+++ b/core/View.php
@@ -43,7 +43,12 @@ class Piwik_View implements Piwik_iView
// global value accessible to all templates: the piwik base URL for the current request
$this->piwikUrl = Piwik_Common::sanitizeInputValue(Piwik_Url::getCurrentUrlWithoutFileName());
- $this->currentUrlWithoutFilename = Piwik_Common::sanitizeInputValue(Piwik_Url::getCurrentUrlWithoutFileName());
+ if(Piwik::isHttps()
+ && strpos($this->piwikUrl, 'http://') === 0)
+ {
+ $this->piwikUrl = str_replace('http://', 'https://', $this->piwikUrl);
+ }
+
$this->piwik_version = Piwik_Version::VERSION;
$this->cacheBuster = md5(Piwik_Common::getSalt() . PHP_VERSION . Piwik_Version::VERSION);
}
@@ -238,6 +243,11 @@ class Piwik_View implements Piwik_iView
/**
* Render the single report template
+ *
+ * @param string $title Report title
+ * @param string $reportHtml Report body
+ * @param bool $fetch If true, return report contents as a string; else echo to screen
+ * @return string Report contents if $fetch == true
*/
static public function singleReport($title, $reportHtml, $fetch = false)
{