- Issue created by @lucian.ilea
Hello!
Thank you for this module. It is really useful to me. I use together with EU Cookie Compliance module and I needed a bridge between the two, so I tried to write some code to solve my case.
Please keep in mind that this is my first patch ever, so it might not be compliant with the rules. Also, it might not be the best approach for this, but I thought I share my solution.
Make the module be aware of the consent status the user gave using the EU Cookie Compliance module. The GDPR module blocks the video, even after the user agreed to the use of cookies.
1. Install EU Cookie Compliance module and configure this module to "Reload page after user clicks the Agree button". This is necessary in order to unblock the videos on the page the user was when agreed to the use of cookies.
2. Install GDPR for YouTube and Vimeo module
3. Add video content on a page
4. Click the "Accept" button on the EU Cookie Compliance banner, to accept the cookies.
5. Reload the page - the videos are blocked.
In the GDPR for YouTube and Vimeo module's JS, check the value of the cookie-agreed cookie. This is the cookie placed by the EU Cookie Compliance module. If the value is different 2 (user consent to the use of cookies), then block all the videos.
Please see the attached patch.
1. Check if my approach is correct.
2. Find a way to use the "eu_cookie_compliance.changeStatus" event to unblock the videos without reloading the page.
N/A
N/A
N/A
Needs work
1.1
Code