Skip to content

Commit

Permalink
[TASK] Add Cookiebot example for OptIn configuration
Browse files Browse the repository at this point in the history
  • Loading branch information
einpraegsam committed Feb 16, 2024
1 parent 2cc6b12 commit 49c3008
Showing 1 changed file with 17 additions and 0 deletions.
17 changes: 17 additions & 0 deletions Documentation/Privacy/OptInAndOptOut.md
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,23 @@ var Lux = LuxSingleton.getInstance();
Lux.optOutAndReload();
```

#### Example usage of OptIn with Cookiebot consent manager

If you want to disable tracking by default and enable tracking via Cookiebot consent manager, you could add a JavaScript
to your page like:

```
<script type="text/javascript">
window.addEventListener('CookiebotOnAccept', function(e) {
if (!Cookiebot.consent.marketing) return;
var Lux = LuxSingleton.getInstance();
Lux.optIn();
}, false);
</script>
```

Note: Do not forget to use `plugin.tx_lux.settings.autoenable=0` via TypoScript setup

### Opt-Out Plugin

As known from Matomo (former known as Piwik) also LUX offers a Plugin for an Opt-Out possibility for visitors. You
Expand Down

0 comments on commit 49c3008

Please sign in to comment.