Jump to content

[Share] Remove Navigation Code

Recommended Posts

Some CSS code to remove Navigation (use to Custom CSS box)

#1. Remove Navigation on One Page

With this code, you need to add it to Page Header Code Injection (if the page doesn't support Code Injection, you can add it via Code Block)

<!-- remove navigation - one page -->
<style>
  header#header nav, .header-burger {
    display: none;
  }
  </style>

#2. Remove Navigation on All Pages

/* remove navigation - all pages */
  header#header nav, .header-burger {
    display: none;
  }

#3. Remove on Blog List Page

/* remove navigation - blog page */
[class*="type-blog"].view-list {
  header#header nav, .header-burger {
    display: none;
  }
}

#4. Remove on Blog Post Detail

/* blog posts */
[class*="type-blog"].view-item {
  header#header nav, .header-burger {
    display: none;
  }
}

#5. Remove on Event List Page

/* event list */
[class*="type-events"].view-list {
  header#header nav, .header-burger {
    display: none;
  }
}

#6. Remove on Event Detail

/* event detail */
[class*="type-events"].view-item {
  header#header nav, .header-burger {
    display: none;
  }
}

#7. Remove on Product Category/Shop

/* shop category page */
[class*="type-products"].view-list {
  header#header nav, .header-burger {
    display: none;
  }
}

#8. Remove on Individual Product

/* individual products */
[class*="type-products"].view-item {
  header#header nav, .header-burger {
    display: none;
  }
}

#9. Remove on Cart Page

/* cart page */
body#cart {
  header#header nav, .header-burger {
    display: none;
  }
}

#10. Remove on Homepage only

/* Homepage only */
body.homepage {
  header#header nav, .header-burger {
    display: none;
  }
}

#11. Remove on Other pages (exclude Homepage)

/* Other page - exclude homepage */
body:not(.homepage) {
  header#header nav, .header-burger {
    display: none;
  }
}

#12. Remove on Scroll

header#header.shrink {
	nav, .header-burger {
		display: none !important;
}
}

If you have any problems, you can comment below.

Email me if you have need any help (free, of course.). Answer within 24 hours. 
Or send to forum message

Contact Customer Care - Learn CSS - Buy me a coffee (thank you!)

Link to comment
  • Replies 0
  • Views 1k
  • Created
  • Last Reply

Top Posters In This Topic

Popular Days

Top Posters In This Topic

Create an account or sign in to comment

You need to be a member in order to leave a comment


×
×
  • 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.