Adding the word "each" after product price in the Ride theme?

Adding the word "each" after product price in the Ride theme?

FPForged
Visitor
2 0 0

Hello, 

 

I am trying to add the word "each" after the price for some products in the Ride Theme. I'm currently working under a duplicated theme so that I can get my products reorganized and updated before everything goes live at the same time. I think I need to change a piece of my code to add text after pricing, but I can't figure out how to accomplish that. Can someone please walk me through how to do that? Thank you! 

Reply 1 (1)

PaulNewton
Shopify Partner
7721 678 1620

‌‌‌‌⚠💣 Always backup themes before changing files 💣⚠‌

 

HI @FPForged 👋 This is an advanced theme customization.

To DIY for static price display, roughly in price.liquid try something like the following 

https://github.com/Shopify/dawn/blob/main/snippets/price.liquid#L38

if product.tags contains "sometagname"
  assign money_price = price | append: " each"
endif

 replace the product.tags logic with whatever the business logic is.

And keep in mind the interaction with price_varies.

 

 

If you need dynamic prices when the variant changes etc. then contact me for services.
Contact info in forum signature.
ALWAYS please provide context, examples: store url, theme name, post url(s) , or any further detail in ALL correspondence.

Good Luck.

 

 

 

Contact paull.newton+shopifyforum@gmail.com for the solutions you need


Save time & money ,Ask Questions The Smart Way


Problem Solved? ✔Accept and Like solutions to help future merchants

Answers powered by coffee Thank Paul with a Coffee for more answers or donate to eff.org