Discuss and resolve questions on Liquid, JavaScript, themes, sales channels, and site speed enhancements.
can you please share your site link and if you can give access of your site i will fix it for you
Go to Online Store -> Themes -> Edit code. Look for snippets and find card-product.liquid
On the line 133 something is not quite right. Would you mind sending here lines 130-135?
>
{{ product_card_product.compare_at_price | minus: product_card_product.price | times: 100 | divided_by: product_card_product.compare_at_price }}% OFF
</span>
replace with this code
{% if product_card_product.compare_at_price > 0 %} {{ product_card_product.compare_at_price | minus: product_card_product.price | times: 100 | divided_by: product_card_product.compare_at_price }}% OFF {% else %} 0% OFF {% endif %}
Okay it worked but now there is 0% off...
{% if product.compare_at_price > 0 %} {{ product.compare_at_price | minus: product.price | times: 100 | divided_by: product.compare_at_price }}% OFF {% else %} {% endif %}
I am guessing this is what you need.
Now it looks like this: but its actually not 30%... 😄
Maybe you can help me also with this: I tried everything but its not wirking.. 😄 just want to center the title... Thanks in advance
Hi. I have same problem with coding of product-price.liquid. Would you be able to advise me the correct using I should replace that line with? Currently I have
<span class="badge sale-badge" data-label-sale> -{{ product.variants[0].compare_at_price | minus:product.variants[0].price | times:100 | divided_by:product.variants[0].compare_at_price }}%</span>
By investing 30 minutes of your time, you can unlock the potential for increased sales,...
By Jacqui Sep 11, 2024We appreciate the diverse ways you participate in and engage with the Shopify Communi...
By JasonH Sep 9, 2024Thanks to everyone who participated in our AMA with 2H Media: Marketing Your Shopify St...
By Jacqui Sep 6, 2024