From 6614bd008a4e52ced4ede2c0d4de67186e3ed462 Mon Sep 17 00:00:00 2001 From: Amauri CHAMPEAUX Date: Tue, 25 Sep 2018 12:30:02 +0200 Subject: [PATCH] Add Adform and Active Campaign --- tarteaucitron.services.js | 44 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 44 insertions(+) diff --git a/tarteaucitron.services.js b/tarteaucitron.services.js index 850cb35..07392fe 100644 --- a/tarteaucitron.services.js +++ b/tarteaucitron.services.js @@ -2338,3 +2338,47 @@ tarteaucitron.services.bingads = { }); } }; + +// Adform +tarteaucitron.services.adform = { + "key": "adform", + "type": "ads", + "name": "Adform", + "uri": "https://site.adform.com/privacy-center/overview/", + "needConsent": true, + "cookies": [], + "js": function () { + "use strict"; + if (tarteaucitron.user.adformpm === undefined) { + return; + } + + window._adftrack = { + pm: tarteaucitron.user.adformpm, + divider: encodeURIComponent('|'), + pagename: encodeURIComponent('WebsiteName|SectionName|SubSection|PageName') + }; + + tarteaucitron.addScript("https://track.adform.net/serving/scripts/trackpoint/async/"); + } +}; + +// Active Campaign +tarteaucitron.services.activecampaign = { + "key": "activecampaign", + "type": "ads", + "name": "Active Campaign", + "uri": "https://www.activecampaign.com/privacy-policy/", + "needConsent": true, + "cookies": [], + "js": function () { + "use strict"; + if (tarteaucitron.user.actid === undefined) { + return; + } + + window.trackcmp_email = ''; + + tarteaucitron.addScript('https://trackcmp.net/visit?actid='+tarteaucitron.user.actid+'&e='+encodeURIComponent(trackcmp_email)+'&r='+encodeURIComponent(document.referrer)+'&u='+encodeURIComponent(window.location.href)); + } +};