How can I remove the sale badge but keep the sold badge in Dawn theme?

Solved

How can I remove the sale badge but keep the sold badge in Dawn theme?

visceralhome
Excursionist
11 1 2

hi friends! I need your help - I’ve been trying to figure this out of weeks now and every code or solution has worked in someways then caused issues in others. 

I use the dawn setting - I want to KEEP the cross out/compare price. But I do not want the sale badge on my products. (Home page, collection pages, est.) - I found a few codes here that did remove the badges - but it removed the sold badge too. 

I really want to keep the sold badge and JUST remove the sale badge. It’s important to me to keep the original price due to it being the price at the gallery so I do not want to have a huge price drop on the website but also do not want to call it a “sale”. 

if anyone can help that would help tremendously !! if you need a reference to what I am talking about my website is 

 

www.visceralhome.com

kindly, taylor + connor robinson.
http://visceralhome.com
Accepted Solution (1)

PageFly-Victor
Shopify Partner
7865 1785 3094

This is an accepted solution.

Hi @Visceralhome,

 

You can try this code by following these steps:

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

Step 2: Search file base.css,

Step 3: Paste the below code at bottom of the file -> Save

PageFlyVictor_0-1673510468903.png

.badge.badge--bottom-left.color-background-2{display:none!important}

PageFlyVictor_1-1673510509413.png

 


Hope my solution works perfectly for you!

Best regards,

Victor | PageFly

View solution in original post

Replies 5 (5)

GemPages
Shopify Partner
5625 1261 1240

Hello @visceralhome ,

 

It's GemPages support team and glad to support you today.

 

I would like to give you the recommendation to support you so kindly follow the steps below:

 

1. Go to Online Store > Theme > Edit code of your current theme

GemPages_0-1673487083401.png


2. Open your theme.liquid theme file


3. Paste the below code before </body>

<script>
let badge = document.querySelectorAll('.badge')
badge.forEach(function(el){
    if (el.innerText.includes("Sale")){
        el.style.display = "none";
    }
})
</script>

 

If you require any further information, feel free to contact me.

 

Best regards,
GemPages Support Team

GemPages - Build any high-converting store pages for any business


- If you find my reply helpful, please hit Like and Mark as Solution
- Get connected: App Store | Blog | Community | Help Center
ajmade
Visitor
1 0 0

This worked for me!!! 🙌 Literally just made an account on here so I could bump this answer because it's the only thing that worked after scouring at least a dozen help articles and testing several solutions that worked for others but not me 😩 The CSS snippets either removed all the badges (including sold out) or didn't work at all; this was the first one I saw that used Javascript and it worked!!! Thank you!!!! 

PageFly-Victor
Shopify Partner
7865 1785 3094

This is an accepted solution.

Hi @Visceralhome,

 

You can try this code by following these steps:

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

Step 2: Search file base.css,

Step 3: Paste the below code at bottom of the file -> Save

PageFlyVictor_0-1673510468903.png

.badge.badge--bottom-left.color-background-2{display:none!important}

PageFlyVictor_1-1673510509413.png

 


Hope my solution works perfectly for you!

Best regards,

Victor | PageFly

visceralhome
Excursionist
11 1 2

Thank you !!! You are AMAZING! A life saver!!! It worked!!!!

kindly, taylor + connor robinson.
http://visceralhome.com
PageFly-Victor
Shopify Partner
7865 1785 3094

Great! I'm glad it works perfectly on your end 😊