Hello, how can you show discount percent on the website (I’m using the Origin theme)
You can do it very easily if you can modify the liquid files.
Just login in your shopify admin store. There you will see the option of online store.
Expand it here you will find the menu Theme.
Then from there you can find the option to edit the code and find “product-price.liquid” file.
In that files you can write the code after line number 12 write the below code
{% if compare_at_price %}
{% capture discount %}
{{ compare_at_price | minus:price | times:100 | divided_by:compare_at_price }}%
{% endcapture %}
{{ discount }}
{% endif %}
here {{ discount }} is you % discount you can use at any place in that liquid file.
Please let me know if it was helpful.
Thanks!
Add liquid code to your snippets/price.liquid file.
The update was done on snippets/price.liquid file only
code is working or not
no its not working

