Create your own cookie consent banner

Hi guys I stumbled on this while doing research for cookie POPI compliance curtesy “GT Coding Learn to code”. GT Coding
Cookie-conseent-Banner.zip (2.9 KB)
I worked through the tutorial and got it to work and understand the concept. It consists of: A sample index.html, style.css and main.js file. kindly see Attached Zip file containing the mentioned files. The issue is that my coding knowledge is limited. I just need someone that can show me how to integrate it with a Blocs project.
I would really appreciate it.

Hey @PeterG,

Pretty straight forward, you can attach the javascript file to the project header (that will put it on every page). Then just create a bloc that has the cookie classes used in the project and make sure its in the global footer area. You could also do this with a modal (see this thread, although this is using cookies, not local storage)

1 Like

Many thanks will give it a try.
Much appreciated :+1::pray:

Hey Malachiman
Thank you for the pointers. I created a block in the footer with the classes as you suggested.
Then attached the css and java file to the project. It works perfect.

Many thanks for help.
PeterG

1 Like