hpolak Posted May 2, 2017 Share Posted May 2, 2017 I'm using $product.price directly in product-list.tpl. This yields "7.05" (for instance). The formatted price would be "7,05 €" This same code is used to display best-sales, but the $product.price value is "7,05 €" instead of the expected (and correct) "7.05". My question is where, how, why is this value changed? I've solved this by the way. {if !strpos($product.price, "€")} {$product.price} {else} {assign var='tmp' str_replace("€", "", $product.price)} {assign var='tmp' str_replace(",", ".", $tmp)} {$tmp} {/if} Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now