From 65500818514b17ec9893aa3957c5d285eca93c4f Mon Sep 17 00:00:00 2001 From: Lukas Winkler Date: Mon, 29 Nov 2021 15:59:05 +0100 Subject: [PATCH] init --- CHANGELOG.md | 3 +++ ExclusionDemo.php | 41 +++++++++++++++++++++++++++++++++++++++++ README.md | 6 ++++++ config/config.php | 2 ++ config/tracker.php | 2 ++ docs/faq.md | 5 +++++ docs/index.md | 1 + plugin.json | 29 +++++++++++++++++++++++++++++ screenshots/.gitkeep | 0 9 files changed, 89 insertions(+) create mode 100644 CHANGELOG.md create mode 100644 ExclusionDemo.php create mode 100644 README.md create mode 100644 config/config.php create mode 100644 config/tracker.php create mode 100644 docs/faq.md create mode 100644 docs/index.md create mode 100644 plugin.json create mode 100644 screenshots/.gitkeep diff --git a/CHANGELOG.md b/CHANGELOG.md new file mode 100644 index 0000000..8546318 --- /dev/null +++ b/CHANGELOG.md @@ -0,0 +1,3 @@ +## Changelog + +Here goes the changelog text. diff --git a/ExclusionDemo.php b/ExclusionDemo.php new file mode 100644 index 0000000..3b2e91e --- /dev/null +++ b/ExclusionDemo.php @@ -0,0 +1,41 @@ + 'isExcludedVisit' + ); + } + + public function isTrackerPlugin() + { + return true; + } + + public function isExcludedVisit(bool &$excluded, Request $request) + { +// var_dump($request->getIp()); + if ($request->getVisitorId() === "something") { + $excluded = true; + } + $params = $request->getParams(); + if ($params["url"] === "something") { + $excluded = true; + } + if ($params["uid"] === "some user id") { + $excluded = true; + } + } +} diff --git a/README.md b/README.md new file mode 100644 index 0000000..8d32a76 --- /dev/null +++ b/README.md @@ -0,0 +1,6 @@ +# Matomo ExclusionDemo Plugin + +## Description + +Add your plugin description here. + diff --git a/config/config.php b/config/config.php new file mode 100644 index 0000000..d266508 --- /dev/null +++ b/config/config.php @@ -0,0 +1,2 @@ +=4.6.0-rc2,<5.0.0-b1" + }, + "authors": [ + { + "name": "Matomo", + "email": "", + "homepage": "" + } + ], + "support": { + "email": "", + "issues": "", + "forum": "", + "irc": "", + "wiki": "", + "source": "", + "docs": "", + "rss": "" + }, + "homepage": "", + "license": "GPL v3+", + "keywords": [] +} \ No newline at end of file diff --git a/screenshots/.gitkeep b/screenshots/.gitkeep new file mode 100644 index 0000000..e69de29