Jump to content

Custom CCS working in editor but doesn't appear on the live site

Recommended Posts

Site URL: https://weselect.com/

So I've been trying to add custom css to our Secondary Navigation to make one of the two buttons outlined. This works fine in the editor but once I load the live site the CSS is not applied. Is there something I'm doing wrong?

This is my Custom CSS:

#yui_3_17_2_1_1580978748119_1195 > div > a:nth-child(1)  {
    color: #213651!important;
    background-color: #ffffff!important;
    border: 1px solid!important;
    border-color: #213651!important;
  }

 

1692524156_Skarmavbild2020-02-06kl_11_27_20.thumb.png.e0f8ab02491c3176855319d7d6cf09e7.png113472684_Skarmavbild2020-02-06kl_11_27_27.thumb.png.7ea0e362837a9407036287d5ec16c738.png

It turns out like this:

113472684_Skarmavbild2020-02-06kl_11_27_27.thumb.png.7ea0e362837a9407036287d5ec16c738.png

 

 

Link to comment
  • Replies 1
  • Views 301
  • Created
  • Last Reply

YUI IDs like the one in your screenshot are dynamically generated on page load. You shouldn't use these in your code because they will change next time the page is refreshed or edited. I published a guide that explains this here: In Squarespace, what are the differences between #block-yui and #yui selectors?

About me: I've been a SQSP User for 18 yrs. I was invited to join the Circle when it launched in 2016. I have been a Circle Leader since 2017. I don't work for Squarespace. I value honesty, transparency, diversity and good design ♥.
Work: I founded and run SF.DIGITAL, building Squarespace Extensions to supercharge your commerce website. 
Content: Views and opinions are my own. Links in my posts may refer to SF.DIGITAL products or may be affiliate links.
Forum advice is free. You can thank me by clicking one of the feedback emojis below. Coffee is optional.

Link to comment

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.