Discuss and resolve questions on Liquid, JavaScript, themes, sales channels, and site speed enhancements.
Hello,
I have separate sale campaigns going. I am wondering if I can change or remove the sales badge from certain products in collection and their product pages.
In the screen shot, you can see the product badges are all "Christmas Sale". I want to leave these on the Christmas Sale and remove or (change if I have to) This badge on the Boxing Day sale products (circled in Blue)
And then on the product page. I would like to change this to "boxing Day sale" - or remove if it is my only options
Please Note: I want to keep the christmas sale badges on the christmas sale and only alter the products that are offered in the "pre-release boxing day sale"
Thank you
Hi @AbbeyJai
We have checked and here is the example on Dawn theme.
- before: https://prnt.sc/WE3OBle2rDAl
- after: https://prnt.sc/C_euTkM7umBD (removed)
Step 1: Check the number here: https://prnt.sc/N0hxu3kd6h2F
Step 2: Add these two snippets to the card-product.liquid file:
https://prnt.sc/thQN1zB1krYD
{% if card_product.id != 8783363178660 %}
{% endif %}
The number is the one just checked in Step 1.
- On the PRODUCT page
before: https://prnt.sc/TLGLKjvVqgbv
after: https://prnt.sc/HASgD6tyHRij
In the price.liquid file,
add these lines of code:
The number is taken from Step 1 above.
https://prnt.sc/pFCWy5uUajo9
{% if product.id == 8783363178660 %}
BOX BOX BOX
{% else %}
{% endif %}
If you use other theme, please share with me the strore URL.
Thank you
This is Brilliant.
I am so sorry, I am so new at this. I know how to get teh java script up, but I do not know what to do or press to do this: Step 1: Check the number here: https://prnt.sc/N0hxu3kd6h2F
When i try and highlight the badge to get the number, it takes me to the product page in stead of highlighting the javascript
I think it would work if I just remove the badge from these particular products. Is there a way to remove the badge from only certain products?
Can you share with me the product link that you want to remove the badge?
Hello Liz, I am so sorry for my late reply. I was able to get hold of one of my coaches over christmas who went in an did it for me quickly. Thank you
Hey Community! As we jump into 2025, we want to give a big shout-out to all of you wh...
By JasonH Jan 7, 2025Hey Community! As the holiday season unfolds, we want to extend heartfelt thanks to a...
By JasonH Dec 6, 2024Dropshipping, a high-growth, $226 billion-dollar industry, remains a highly dynamic bus...
By JasonH Nov 27, 2024