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:
authorsgiehl <stefan@piwik.org>2014-09-10 23:22:08 +0400
committersgiehl <stefan@piwik.org>2014-09-10 23:22:08 +0400
commit9bbab61835b83240cfc9060b8a1e9f28a95154e2 (patch)
treeb7f3325763bbcefc78b31c4d4650eef042681200 /core/Piwik.php
parent25545fdc55a1decd13548c1f3f6479789956e56c (diff)
refs #6174 - added possibility to add 'disableCookies' option in tracking code generator
Diffstat (limited to 'core/Piwik.php')
-rw-r--r--core/Piwik.php5
1 files changed, 4 insertions, 1 deletions
diff --git a/core/Piwik.php b/core/Piwik.php
index 9e53964e60..ccaee84962 100644
--- a/core/Piwik.php
+++ b/core/Piwik.php
@@ -131,7 +131,7 @@ class Piwik
public static function getJavascriptCode($idSite, $piwikUrl, $mergeSubdomains = false, $groupPageTitlesByDomain = false,
$mergeAliasUrls = false, $visitorCustomVariables = false, $pageCustomVariables = false,
$customCampaignNameQueryParam = false, $customCampaignKeywordParam = false,
- $doNotTrack = false)
+ $doNotTrack = false, $disableCookies = false)
{
// changes made to this code should be mirrored in plugins/CoreAdminHome/javascripts/jsTrackingGenerator.js var generateJsCode
$jsCode = file_get_contents(PIWIK_INCLUDE_PATH . "/plugins/Morpheus/templates/javascriptCode.tpl");
@@ -182,6 +182,9 @@ class Piwik
if ($doNotTrack) {
$options .= ' _paq.push(["setDoNotTrack", true]);' . PHP_EOL;
}
+ if ($disableCookies) {
+ $options .= ' _paq.push(["disableCookies"]);' . PHP_EOL;
+ }
$codeImpl = array(
'idSite' => $idSite,