Liquid, JavaScript, themes, sales channels
Hi,
How to achieve following format for whole eshop?
Format:
€ 1 650
I found this working but i don't want to format price everywhere:
price | money_without_trailing_zeros | replace: ".", " "
And also i found this https://shopify.dev/docs/themes/liquid/reference/filters/money-filters but it don't seem to cover my use case as well.
Is there any possibility to format price globally with format above?
Solved! Go to the solution
This is an accepted solution.
Hey, @lukas-irsak
There's actually a dedicated area in your Shopify settings where you can change the global formatting of your store's currency. I've taken a screenshot below to show you how this can be accomplished in your Settings > General page:
I hope this helps! If there is anything else I can help you with, please let me know.
Dirk | Social Care @ Shopify
- Was my reply helpful? Click Like to let me know!
- Was your question answered? Mark it as an Accepted Solution
- To learn more visit the Shopify Help Center or the Shopify Blog
This is an accepted solution.
Hey, @lukas-irsak
There's actually a dedicated area in your Shopify settings where you can change the global formatting of your store's currency. I've taken a screenshot below to show you how this can be accomplished in your Settings > General page:
I hope this helps! If there is anything else I can help you with, please let me know.
Dirk | Social Care @ Shopify
- Was my reply helpful? Click Like to let me know!
- Was your question answered? Mark it as an Accepted Solution
- To learn more visit the Shopify Help Center or the Shopify Blog
Awesome, thank you 🙂
Thank you for the great tip @Dirk ! Is there also a way to remove the space? By that I mean no separators at all. I would love to have $2500 instead of $2 500 / $2,500. Thank you!
Hey, @LeonL
For this, I would suggest checking out an older forum topic where this was brought up here. There are some snippets of code provided that may prove to be useful!
Note: Be sure to duplicate your theme before editing theme files. In case something breaks, you have a working theme file still.
If there is anything else I can help you with, please let me know
Dirk | Social Care @ Shopify
- Was my reply helpful? Click Like to let me know!
- Was your question answered? Mark it as an Accepted Solution
- To learn more visit the Shopify Help Center or the Shopify Blog
Dear @Dirk Thank you for taking your time in replying! Yes, I noticed this post before, but it's from year 2013 and I guess the code has been changed. Would you have any idea where to look for the snippet files, what @Caroline_Schnap suggested at the end of your mentioned forum topic?
I am using Debut theme and cannot find the place where to replace the
| money
with:
| money | remove: ','
Thank you!
Hey, @LeonL
Editing the 'product-price' snippet will remove the , in your pricing on each product page:
Dirk | Social Care @ Shopify
- Was my reply helpful? Click Like to let me know!
- Was your question answered? Mark it as an Accepted Solution
- To learn more visit the Shopify Help Center or the Shopify Blog
Thanks a lot @Dirk I particullary value the fact that you are taking your time to reply in even Solved threads! Your solution worked like a charm! I just want to add to those who are also searching for this - one must also edit product-price-listing.liquid the same way, so the comma is also removed on all listings and collection pages, not just an opened product page.
Thank you once again! More people like you and the world will be a better place one day.
Happy to help @LeonL! Glad it worked out for you in the end.
Dirk | Social Care @ Shopify
- Was my reply helpful? Click Like to let me know!
- Was your question answered? Mark it as an Accepted Solution
- To learn more visit the Shopify Help Center or the Shopify Blog
To anyone fighting this in 2023, some settings in Shopify has been changed and the solution that worked in Debut theme for my new shop goes for me as this:
1. Settings > General > Store currency > Change formatting:
2. Then Edit theme code. Modify the line in both product-price.liquid and product-price-listing.liquid to this:
assign money_price = price | money | remove: '.'
In my case, it was around lines 23, 24, but could differ. Screenshot from my new code that worked below:
User | RANK |
---|---|
37 | |
28 | |
13 | |
13 | |
9 |
Make the shift from discounts to donations, and witness your business not only thrive fina...
By Holly Dec 4, 2023On our Shopify Expert Marketplace, you can find many trusted third party developers and fr...
By Arno Nov 27, 2023You've downloaded the Search & Discovery app from the Shopify App store, and as you're ...
By Skye Nov 8, 2023