klaro-js
klaro-js copied to clipboard
Pressing "I Decline" Not Working As Expected With Contextual Consent
I have problem with "Contextual Consent"
I am using klaro.js V18
I have an embedded youtube video and I am using "Contextual Consent" to ensure Google cookies are not downloaded without consent from the user
Expected Behaviour
- Go to my website
- Press I Decline On Consent Notice
- Embedded YouTube Video not downloaded
Actual Behaviour
- Go to my website
- Press "I Decline" On Consent Notice
- Embedded YouTube Video Downloads
Notes
However from the Consent Notice if I choose "Let Me Choose" then on the Consent Modal I toggle off the "Marketing" option AND then press "Accept Selected", I get the expected behaviour re the youtube video.
So I can get the expected behaviour by using the Consent Modal, but not through the Consent Notice.
Have I set up my config file correctly ? Thanks
var klaroConfig = { privacyPolicy:'/privacy', cookiexpiresAfterDays: 120, mustConsent: false, acceptAll: true, hideDeclineAll: false, hideLearnMore: false, lang: 'en', translations: { en: { //consentNotice: { //extraHTML: "
Please look at our <a href="#imprint">Imprint for further information.
", //}, consentModal: { description: 'Here you can see and customise the information that we collect about you.', }, purposes: { analytics: {title:'Analytics'} }, }, },services:[ { name: 'googleAnalytics', default: true, title: 'Google Analytics', description:'This tool helps us understand vistitor volumes and how they use our site so that we can make changes and improvements to further enhance the experience ', purposes:['analytics'], }, { name:'demo-youtube', purposes:['marketing'], contextualConsentOnly:true, default:true, }, ], };
HTML Code of Page