Jump to content

How to customize the cookie banner?

Recommended Posts

Posted

Hi everyone,

I am fighting with my cookies banner.. would need some help if anyone available.

1 - To give more context, as there is no editable cookie banner in my template I had to inject some code.

Here is the code I injected within the footer (coming from another question on the forum):

For some reason, the banner doesn't remain at the bottom when I scroll down the site.It goes up as I scroll down.... any idea why?

2 - Is there any way I could customize the size/typo of the text and the "call to action" which asks the customer to click on "Continue"?

3- Any chance I can change the color of the banner ?From grey'ish to white ideally (transparency too)

4- Finally the banner doesn't cover the full width of the screen (this happens on desktop only)I guess it is linked to the length of the text within the banner but I was wondering if there was any way to customize this too so it covers the width

Hopefully it makes sense...

Thanks a lot in advance!

ps: I cannot share my website as it's not live yet. Hopefully not a blocker.

  • Replies 15
  • Views 6.6k
  • Created
  • Last Reply
Posted

I suggest you post a link to your site so that we can see the code working. A trial site address of something.squarespace.com is fine.

Me: I'm Paul, a SQSP user for >18 yrs & Circle Leader since 2017. I value honesty, transparency, diversity and good design ♥.
Work: Founder of SF.DIGITAL. We provide high quality original extensions to supercharge your Squarespace website. 
Content: Views and opinions are my own. Links in my posts may refer to my own SF.DIGITAL products or may be affiliate links.
Forum advice is completely free. You can thank me by selecting a feedback emoji. Buying a coffee is generous but optional.

Posted

Hi @kenwestphal, sure!I'm using Clay template. For some reason, the code didn't go through with my previous message...

code.png.0264e540998c7e5b830292c47b00f5ce.png

Posted

Hi @kenwestphal,cannot post 2 attachments at the same time for some reason..

Here is a screenshot of the site.

cookies-banner.png.bbc6832e758b8a0d5b01e385246abcbb.png

Posted

Hi @Paul2009 unfortunately it will redirect you to the same password page.I'm planning to release it this week. Hopefully the screenshots I've posted previously can help you understand the situation...

Posted

Thanks @Tal

I do see you are using the code from the Squarespace Help guide for the Cookie Banner - https://support.squarespace.com/hc/en-us/articles/206545727-Adding-a-cookie-banner

I'm not an expert in JavaScript and I didn't find much info searching, but you'd have to add CSS to the JavaScript code to be able to do the customizations you want. Hopefully someone who knows JavaScript will be able to provide the code that can be used for this.

  • 5 months later...
Posted

Is anyone know how to make the cookie banner scroll down the whole page like how that happened in square page home page? When the page is full load the banner push the page down and when you click continue or the x the page goes up again. Does anyone know how to do the same to my website? www.harrysdim.com

Posted

Is anyone know how to make the cookie banner scroll down the whole page like how that happened in square page home page? When the page is full load the banner push the page down and when you click continue or the x the page goes up again. Does anyone know how to do the same to my website? www.harrysdim.com

  • 8 months later...
Posted

I followed the example above (Sound Focus) and it works perfectly, however my site uses a cover page in front of the main site. The cookie bar still had the default Squarespace look. I injected the same code into the header of the cover page but had display issues. Does anyone know if there is some code that will hide the cookie bar from a cover page while leaving intact everywhere else on the site?

Posted

@danjc

You should be able to add this line of code to the Cover Page "advanced" section within the Page Header Code Injection area to hide the cookie banner from the Cover Page only


.cookie-notice {display:none !important;}


Posted

Thanks for your reply @kenwestphal, but this code didn't work for me. Does it need to be in between tags or anything?

Posted

@danjc

My apologies - Yes you would need to put the CSS code in between Style tags. I assumed you knew that and/or already had Style tags in place. Hopefully the below helps you.


<style>
.cookie-notice {display:none !important;}
</style>


Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Squarespace Webinars

Free online sessions where you’ll learn the basics and refine your Squarespace skills.

Hire a Designer

Stand out online with the help of an experienced designer or developer.