FEATURE: Add do_not_track and disableCookies settings (#2)

This commit is contained in:
kees-closed 2022-10-04 15:25:56 +02:00 committed by GitHub
parent bbd0dcb82d
commit a488709d75
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 16 additions and 0 deletions

View File

@ -33,6 +33,14 @@
_paq.push(["setDomains", allDomains]);
}
if (settings.do_not_track) {
_paq.push(["setDoNotTrack", true]);
}
if (settings.disable_cookies) {
_paq.push(["disableCookies"]);
}
_paq.push(["setCustomUrl", url]);
_paq.push(["setDocumentTitle", title]);
_paq.push(["trackPageView"]);

View File

@ -17,3 +17,11 @@ subdomain_tracking:
type: bool
default: false
description: Track visitors across main domain & subdomains, assuming discourse is on a subdomain.
do_not_track:
type: bool
default: false
description: So tracking requests will not be sent if visitors do not wish to be tracked.
disable_cookies:
type: bool
default: false
description: Disables all first party cookies. Existing Matomo cookies for this website will be deleted on the next pageview.