Jump to content

Making a Section in my Store Disappear after a category is selected

Recommended Posts

Posted

Site URL: https://www.auntyhong.sg/

Hi, 

I have a section in my main store page called "Categories" where my three categories of SKUs are displayed. 

I would like that section to disappear on the individual category sub-pages so that users do not need to scroll down through the categories again. 

Appreciate any help with this!


The site is auntyhong.sg. It is alr live.

  • Replies 1
  • Views 315
  • Created
  • Last Reply
Posted

Given that you'll only have these 3 pages where you want to remove that section, this CSS should remove it.

#collection-5fe06096f3f88b619f3aecbb section[data-section-id="5feaa679403aca2b594ef4ef"], #collection-5fe06096f3f88b619f3aecbb section[data-section-id="5feaa679403aca2b594ef4ef"], #collection-5fe06096f3f88b619f3aecbb section[data-section-id="5feaa679403aca2b594ef4ef"] {
  display: none;
}

But if you add more categories, we'll have to either add more code to the above, or get fancier with our coding logic.

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.