Shopify themes, liquid, logos, and UX
Hey,
Is There a way to show the "Cross-Over Price" In the cart drawer? I will add an image of the issue and outcome below. Thanks in advance!
My site url: https://bellevodesign.com/
The Issue:
The Desired Outcome:
Solved! Go to the solution
This is an accepted solution.
Try this
snippets -> cart-drawer.liquid
at line no. 159 replace this code
{{ item.original_price | money }}
with this one
<div class="price__sale" style=" display: block; ">
{% if item.variant.compare_at_price > item.final_price %}
<span> <s class="price-item price-item--regular">{{ item.variant.compare_at_price | money }}</s></span>
{% endif %}
<span class="price-item price-item--sale price-item--last">{{ item.original_price | money }}</span>
</div>
Hello @bellevo ,
Use this code
<div class="price__sale" style=" display: block; ">
{% if item.variant.compare_at_price > item.final_price %}
<span> <s class="price-item price-item--regular">{{ item.variant.compare_at_price | money }}</s></span>
{% endif %}
<span class="price-item price-item--sale price-item--last">{{ item.final_price | money }}</span>
</div>
Instructions I think you already know btw if not use it in
Sections -> cart-notification-product.liquid
I use it at line no. 43 just after {%- endfor -%} and before </dl>
Thanks
Hey, this didn't work for some reason.
Didnt change anything in the cart drawer:
I'm using Dawn theme version 15.0.2
And here you can check
https://client-store-5.myshopify.com/products/tiffany-co-edwardian-vintage-engagement-ring-2674
Hey,
It doesn't work on your page either.
It's a cart page not a cart drawer/popup.
Check your initial question you asked for the cart drawer not for the cart page.
btw you can use the same code for the cart page.
I know, the code does not work in the cart drawer.
Now what I can say.
btw you can check in the screenshot
Does not work on my page for some reason. You can see from my screenshot.
Does not change anything in the drawer
This is an accepted solution.
Try this
snippets -> cart-drawer.liquid
at line no. 159 replace this code
{{ item.original_price | money }}
with this one
<div class="price__sale" style=" display: block; ">
{% if item.variant.compare_at_price > item.final_price %}
<span> <s class="price-item price-item--regular">{{ item.variant.compare_at_price | money }}</s></span>
{% endif %}
<span class="price-item price-item--sale price-item--last">{{ item.original_price | money }}</span>
</div>
This works, thank you so much
We 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, 2024The Hydrogen Visual Editor is now available to merchants in Shopify Editions | Summer '...
By JasonH Sep 2, 2024