Cookie consent. - Post ID 256794

User 187934 Photo


Senior Advisor
20,266 posts
Online Now

Seems to work here.
http://ericrohloff.com/coffeecup/ccforu … cookiebar/
I can't hear what I'm looking at.
It's easy to overlook something you're not looking for.

This is a site I built for my work.(RSD)
http://esmansgreenhouse.com
This is a site I built for use in my job.(HTML Editor)
https://pestlogbook.com
This is my personal site used for testing and as an easy way to share photos.(RLM imported to RSD)
https://ericrohloff.com
User 271657 Photo


Ambassador
3,816 posts

You might want to try the one from Silktide (linked above).
Easy install wizard here: https://silktide.com/tools/cookie-consent/download/
Lightweight: ~3.5kb minified, and no JQuery or other dependencies.
Customisable: Easily change the wording to fit your site.
Themeable: We’ve created a variety of built-in themes and you can create your own.
I love deadlines. I like the whooshing sound they make as they fly by. (Douglas Adams)
https://www.callendales.com
User 371172 Photo


Registered User
35 posts

Finally got it to work as follows::D

Uploaded jquery.cookiebar.js and jquery-1.11.3.min.js to my RSD created 'js' subfolder on my website.
Uploaded jquery.cookiebar.css to the 'css' subfolder.

Files attached:

Added the following script to the footer on the settings tab in RSD:

<script type="text/javascript" src="js/jquery.1.11.3.min.js"></script>
<link rel="stylesheet" type="text/css" href="css/jquery.cookiebar.css" />
<script type="text/javascript" src="js/jquery.cookiebar.js"></script>
<script>
$(document).ready(function(){
$.cookieBar({
fixed: true,
bottom: true,
});
});
</script>

Uploaded the site using FileZila (I cannot get Coffeecup Direct FTP to run smoothly - keeps stalling) and hey presto it works. One minor niggle. The CSS line for the description font colour gets ignored and only displays in black. You can see this happening on Eric's demo site. Don't know why and I couldn't sort it. Maybe one of the code gurus out there can figure it out?

Cheers JP
Attachments:
JP
Cat herder and Fog platter.
User 187934 Photo


Senior Advisor
20,266 posts
Online Now

Add this line to a custom.css and add it to your resources or upload it to your site.
#cookie-bar p{color:#FFFFFF;}

Then add this to your pages head area.
<link href="css/custom.css" rel="stylesheet">
I can't hear what I'm looking at.
It's easy to overlook something you're not looking for.

This is a site I built for my work.(RSD)
http://esmansgreenhouse.com
This is a site I built for use in my job.(HTML Editor)
https://pestlogbook.com
This is my personal site used for testing and as an easy way to share photos.(RLM imported to RSD)
https://ericrohloff.com
User 371172 Photo


Registered User
35 posts

Thanks Eric. Works Perfectly. For my education: do you now why it was ignoring that bit of the css file?

regards JP
JP
Cat herder and Fog platter.
User 187934 Photo


Senior Advisor
20,266 posts
Online Now

RSD <p> is overriding it so you just need a more precise selector.
I can't hear what I'm looking at.
It's easy to overlook something you're not looking for.

This is a site I built for my work.(RSD)
http://esmansgreenhouse.com
This is a site I built for use in my job.(HTML Editor)
https://pestlogbook.com
This is my personal site used for testing and as an easy way to share photos.(RLM imported to RSD)
https://ericrohloff.com

Have something to add? We’d love to hear it!
You must have an account to participate. Please Sign In Here, then join the conversation.