Quantcast
Channel: WordPress.org Forums » All Topics
Viewing all articles
Browse latest Browse all 59525

Hide weight unit (for example kg) in frontend

$
0
0

Replies: 0

I’m working on site that sells social media promoters. I want to use product WEIGHT as another purpose, in this case followers. So if product (person) has 50.000 followers, I set weight to 50.000 grams. This displays as followers in frontend product page and I have code sniplet that sums up all cart “weights” and displays “Total reach:” in cart summary.

Everything works as expected, but I’d like to hide weight unit in frontend. So I want it to show just “50.000”, not “50.000 g”.

Any ideas how to strip off this weight unit, in this case grams = “g” ?


Viewing all articles
Browse latest Browse all 59525

Trending Articles