-
Notifications
You must be signed in to change notification settings - Fork 7
Expand file tree
/
Copy pathoptions.php
More file actions
35 lines (27 loc) · 1.08 KB
/
options.php
File metadata and controls
35 lines (27 loc) · 1.08 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
<?php
// Set the relative URI when the reverse proxy is running in a folder.
// If your proxy runs under https://example.com/stats, then set /stats as relative URI and otherwise just leave the string blank.
$relativeUri = '/stats';
// Set all allowed URI which should be accessible through the proxy
$whitelist = [
'/js/script.js',
'/js/script.outbound-links.js',
'/api/event'
];
// Optional, map allowed URI to another for sanitizing any proofs of Plausible Analytics in the URI.
// If not needed then leave the array empty.
$mapping = [
'/foo/bar.js' => '/js/script.outbound-links.js'
];
// Set visitor IP addresses as exclusion (e.g. for yourself or developers)
// If not needed then leave the array empty.
$excluded = [
'127.0.0.1',
'::1',
];
// Set URL of Plausible Analytics
$backendUrl = "https://plausible.io";
// Script when running under a folder:
// <script defer data-domain="example.com" data-api="/stats/api/event" src="/stats/js/script.js"></script>
// Script when running in the root:
// <script defer data-domain="example.com" src="/js/script.js"></script>