Re: Fixed amount of money

How can I show a dynamic currency bar on my website?

divadminlocal
Tourist
12 0 1

I have a problem. i have to show a bar at the top of the website, and when somebody reach 50€ of shipping they are free. But if somebody see the website in USD currency this 50€ should be like 47 $ or whatever.
I've tried like that: {{ 5000 | money_with_currency }}

but is rendered always 50,00 and change just the symbol of the currency.

I expect something like: {{ 50,00 € | money_with_currency }}.

 

I mean, should not be something crazy to do, but maybe in this case liquid can't help.

 

Let me know!

Because for now to reach anyway this result, i've created another product that is now shown with the value of 50€, and then i've called the price of this product where i want to show this price. The code is this:

{% for product in collections.all.products %}
{% case product.id %}
{% when 8639645516114 %}
{% assign my_product = product %}
{% endcase %}
{% endfor %}

+<span>{{ my_product.price | money_with_currency }}</span> 

But is super long and should not be so hard :')

Replies 4 (4)

Dan-From-Ryviu
Shopify Partner
10963 2150 2289

Hi @divadminlocal 

You can try this code and check

<span>{{ my_product.price | money_without_trailing_zeros | money_with_currency }}</span> 

- Solved it? Hit Like and Accept solution or ❤️Buy Me Coffee❤️
- Reton: Loyalty & Rewards - Earn points through tasks, redeem for discounts, and enjoy exclusive VIP rewards!
- Ryviu - Reviews & QA app: Collect product reviews, import reviews from AliExpress, Amazon, Etsy, Walmart, Shopee, Dhgate and CSV.
- Lookfy Gallery: Lookbook Image: Easy and fast to create Photo Gallery, Lookbook, Shop The Look.
- Reelfy‑Shoppable Videos+Reels: Create shoppable videos to engage customers and drive more sales.
- Enjoy 1 month of Shopify for $1. Sign up now.

divadminlocal
Tourist
12 0 1

Hi! you probably misunderstand. In this way i still have to create the product just for this purpose and i don't want to. 

I need a different solution than this one (that is just working but is a very bad way to do it)

Made4uo-Ribe
Shopify Partner
9870 2351 2947

Hi @divadminlocal 

 

If you have Markets open to international, the currency get updated as per conversion. From your admin page, go to Settings, then Markets. You should be able to configure the shipping in the said country as well. So you can apply your free shipping configuration. Your code for <span> should work in other countries. 

 

 

If this fixed your issue, Likes and Accept as Solution are highly appreciated. Coffee tips fuel my dedication.
Get experienced Shopify developers at affordable rates—visit Made4Uo.com for a quick quote!
Need THEME UPDATES but have custom codes? No worries, for an affordable price.
divadminlocal
Tourist
12 0 1

Hi, as I've said I've just tried in this way, and the result is that is rendered always 50 + the symbol of the currency. That yes, it change when the currency of the website get changed, but the amount of money stay the same, so is not converted.