Empire Theme - Sticky Announcement Bar

Solved

Empire Theme - Sticky Announcement Bar

ProceptMarketin
Shopify Partner
13 0 1

Cannot make the announcement bar sticky. Any solutions? 

Accepted Solution (1)

topnewyork
Globetrotter
633 113 134

This is an accepted solution.

Hi @ProceptMarketin , 

1. Go to Online Store -> Theme -> Edit code.
2. Open your theme.liquid file
3. In theme.liquid, paste the below code before </head>

 

 

<style>
.announcement-bar {
    position: fixed !important;
    top: 0;
    left: 0;
    width: 100vw;
}

.site-header-sticky .site-header {
    top: 47px !important;
}
</style>

 

topnewyork_0-1725286364161.png

 

If my reply is helpful, kindly click like and mark it as an accepted solution.

Thanks!

Need a Shopify developer?
Hire us at Top New York Web Design
For Shopify Design Changes | Shopify Custom Coding | Custom Modifications
Subscribe to our youtube channel

View solution in original post

Replies 5 (5)

topnewyork
Globetrotter
633 113 134

This is an accepted solution.

Hi @ProceptMarketin , 

1. Go to Online Store -> Theme -> Edit code.
2. Open your theme.liquid file
3. In theme.liquid, paste the below code before </head>

 

 

<style>
.announcement-bar {
    position: fixed !important;
    top: 0;
    left: 0;
    width: 100vw;
}

.site-header-sticky .site-header {
    top: 47px !important;
}
</style>

 

topnewyork_0-1725286364161.png

 

If my reply is helpful, kindly click like and mark it as an accepted solution.

Thanks!

Need a Shopify developer?
Hire us at Top New York Web Design
For Shopify Design Changes | Shopify Custom Coding | Custom Modifications
Subscribe to our youtube channel
ProceptMarketin
Shopify Partner
13 0 1

This worked perfectly. Thank you!! 

ProceptMarketin
Shopify Partner
13 0 1

https://coastalpumps.com/products/2024-10x8-trailer-mounted-pump-package

If you see here, i'm having some issues with this code we implemented causing overlay on the page. The title is cut off

BSSCommerce-B2B
Shopify Partner
1503 430 486

@ProceptMarketin ,

Step 1: Go to Shopify Admin -> Online Store ->Theme -> Edit code

Step 2: Search file theme.liquid

Step 3: Insert this code above </head> tag: 

 

<style>
 .announcement-bar {
     position: fixed!important;
     width: 100%;
     top: 0;
 }
 header {
   top: 48px!important;
   margin-top: 48px!important;
 }
</style>

 

result:

BSSCommerceB2B_0-1725286385193.png

 

If it helps you, please like and mark it as the solution.

Best Regards 😍

B2B Wholesale Solution: Streamline your B2B operation with advanced features like wholesale registration forms, custom pricing.


B2B Portal, Quote, Net 30: Speed up purchasing and streamline your quotation process with advanced features like quick order, request for quote.


B2B Lock Password Protect: Easily control access to pages, products, and pricing with robust features.


BSS Commerce - Full-service eCommerce Agency I Use Shopify for 1$ in the first month now

BSSCommerce-HDL
Shopify Partner
2123 760 965

Hi @ProceptMarketin

Step 1: Go to Shopify Admin -> Online Store ->Theme -> Edit code

Step 2: Search file theme.liquid

Step 3: Insert this code above </head> tag:

 

<style>
.announcement-bar {
    position: fixed !important;
    top: 0;
    left: 0;
    width: 100vw;
}

.site-header-sticky .site-header {
    top: 48px !important;
}
</style>

 

 

Here is result: 

BSSCommerceHDL_0-1725286098755.png

Hope this can help you,

If our suggestions are useful, please let us know by giving it a like or marking it as a solution. Thank you 😍

 

If our suggestions are useful, please let us know by giving it a like, marking it as a solution.

Simicart: Transform your Shopify store into a stunning and fully functional mobile app with just a few simple steps.
Product Labels & Badges:
Get more sales with striking labels, badges, and banners from our 10,000+ available templates.

BSS Commerce - Full-service eCommerce Agency | Use Shopify for 1$ in the first month now