diff options
| author | aura <nw@moneybot.cc> | 2026-02-17 22:39:42 +0100 |
|---|---|---|
| committer | aura <nw@moneybot.cc> | 2026-02-17 22:39:42 +0100 |
| commit | 636b0323075225c584b62719ed51e75521bb7ffb (patch) | |
| tree | 61b02271b6d0695a4beffc23fb6eb062a7da22c3 /backend/instance/nocookies/data/js/common3.js | |
push source
Diffstat (limited to 'backend/instance/nocookies/data/js/common3.js')
| -rw-r--r-- | backend/instance/nocookies/data/js/common3.js | 61 |
1 files changed, 61 insertions, 0 deletions
diff --git a/backend/instance/nocookies/data/js/common3.js b/backend/instance/nocookies/data/js/common3.js new file mode 100644 index 0000000..ffb3c58 --- /dev/null +++ b/backend/instance/nocookies/data/js/common3.js @@ -0,0 +1,61 @@ +function getItem(hostname)
+{
+ switch (hostname)
+ {
+ case 'ants.gouv.fr': return {strict: true, key: 'cookieConsent', value: 'true'};
+ case 'eqmac.app': return {strict: false, key: 'EQM_PRIVACY_CONSENT_CHOSEN', value: 'true'};
+ case 'figuya.com': return {strict: false, key: 'cookie-dialog', value: 'closed'};
+ case 'scoodleplay.be': return {strict: false, key: 'scoodleAllowCookies', value: 'true'};
+ case 'lifesum.com': return {strict: false, key: 'accepted-cookies', value: '[]'};
+ case 'programmitv.it': return {strict: false, key: 'privacy_choices_made', value: 'OK'};
+ case 'nexus.gg': return {strict: true, key: 'cookie-notice:accepted', value: 'true'};
+ case 'streamelements.com': return {strict: true, key: 'StreamElements.gdprNoticeAccepted', value: 'true'};
+ case 'blaetterkatalog.welt.de': return {strict: true, key: 'DM_prefs', value: '{"cookie_hint":true,"accept_cookies":false,"_childs":[],"_type":1}'};
+
+ case 'phoenix.de': return {strict: false, key: 'user_anonymous_profile', value: '{"config":{"tracking":false,"userprofile":false,"youtube":false,"twitter":false,"facebook":false,"iframe":false,"video":{"useSubtitles":false,"useAudioDescription":false}},"votings":[],"msgflash":[],"history":[]}'};
+
+ case 'volkskrant.nl':
+ case 'dg.nl':
+ case 'demorgen.be':
+ case 'trouw.nl':
+ case 'ad.nl':
+ case 'parool.nl':
+ case 'ed.nl':
+ case 'bndestem.nl':
+ case 'weser-kurier.de':
+ return [
+ {strict: false, key: 'vl_disable_tracking', value: 'true'},
+ {strict: false, key: 'vl_disable_usecookie', value: 'necessary'}
+ ];
+ }
+
+
+ const parts = hostname.split('.');
+
+ if (parts.length > 2)
+ {
+ parts.shift();
+ return getItem(parts.join('.'));
+ }
+
+ return false;
+}
+
+
+let hostname = document.location.hostname.replace(/^w{2,3}\d*\./i, ''),
+ counter = 0,
+ items = getItem(hostname);
+
+if (items) {
+ (items instanceof Array ? items : [items]).forEach(function(item) {
+ let value = localStorage.getItem(item.key);
+
+ if (value == null || (item.strict && value != item.value)) {
+ localStorage.setItem(item.key, item.value);
+ counter++;
+ }
+ });
+
+ if (counter > 0)
+ document.location.reload();
+}
\ No newline at end of file |
