Closed vrghost242 closed 7 years ago
Not really sure about that GA code that you pasted above (by mistake probably)... It's got nothing to do with cookie-banner?
Can you download the zip, extract it and run the demo? (just open it in your browser locally, basic tests/demo should work that way too...)
I'm not able to reproduce the issue you described above -- eg., every reload of demo.html shows the cookie banner even if you dismiss it by clicking "nooo!1" (since the cookie setting doesn't work locally, that's expected behavior)
Love this solution, simple, straight forward and seems to work well.
However, I found what I think is a bug. If you load the page it comes up perfectly, but if I then do a refresh on the page, the banner does not load, not certain if from a regulatory point of view this would meet the requirements. I changed the code to set the "true" option for wait as below, but still same behaviour: new CookiesEuBanner(function(){ (function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){ (i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o), m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m) })(window,document,'script','//www.google-analytics.com/analytics.js','ga');
Of course, if it is that regulations wise, its ok that it disappears after refresh I am happy to keep it the way it currently is.