• Hello,

    Some products displays a wrong price.
    This one for example has a price of € 19,95… but for some reason it displays as € 19,00 while other products of € 19,95 are displayed correctly.

    This happened before, I had to remove the product and add it again.
    I almost got in trouble at work because of this.

    I’ve cleared all caches and transients, but it didn’t solve our problem.
    I’m very worried because more prices are being corrupted like that, we’ll get in trouble.

    Can someone please help us find a way to solve this?

    https://wordpress.org/plugins/woocommerce/

Viewing 10 replies - 1 through 10 (of 10 total)
  • I am not sure about your problem, because you mentionede that some are wrong some are correct!

    But I can suggest you to look for the “Tax” section of Woocommerce.

    There has to be a “rounding” setting which will cause calculating and of course displaying wrong prices.

    Thread Starter FadingMusic

    (@fadingmusic)

    Hello ManusH,

    Thank you for your quick reply. I tried to disable rounding for the tax section of WooCommerce. I deleted cache and transients afterwards, unfortunately that didn’t solve the problem.

    Plugin Author Mike Jolley (a11n)

    (@mikejolley)

    Your prices include tax. Prices will be shown to the user excluding tax if they are outside of the tax zone. The customer location is geolocated, or follows the ‘default customer address’ setting.

    If you go to the cart page, enter an address in your country, the prices will reflect this.

    Thread Starter FadingMusic

    (@fadingmusic)

    Hello Mike,

    Thank you kindly for your reply.

    All prices do include tax, which is 21%. We’re talking about a difference of € 0,95 instead of the excluding tax, of about € 4,18.

    I’ve managed to solve the problem by deleting the price and saving the product, and then re-adding the price and saving the product.

    I think we might be looking at a bug.

    Plugin Author Mike Jolley (a11n)

    (@mikejolley)

    Did you import said products? Maybe imported with comma which is invalid. We STORE prices with ‘.’ decimals to avoid the cent figure being discarded when converted to a float.

    Thread Starter FadingMusic

    (@fadingmusic)

    Hello Mike,

    No, I did not import any products.
    It sometimes happens with existing product and also with adding new products.

    We do however use commas for our prices.

    Plugin Author Mike Jolley (a11n)

    (@mikejolley)

    When saved, commas are converted to decimals. If the prices was imported, or set via 3rd party plugin, it may lack this conversion and show the issue you mentioned..

    Thread Starter FadingMusic

    (@fadingmusic)

    I’ve checked if there’s any 3rd party plugin that might cause the issue that you mentioned, but I couldn’t find any.

    Do you happen to know which template is most likely to cause this issue? I’ve checked the archive and single, but both seem ok.

    Plugin Author Mike Jolley (a11n)

    (@mikejolley)

    It’s not a template issue. When the price is retrieved from the database as a string, its converted to a float.

    19.95 string = 19.95 float
    19,95 string = 19.00 float.

    Thread Starter FadingMusic

    (@fadingmusic)

    Thank you kindly for your reply, I think I get what you mean.
    I still wonder why it happens with just a few products, and not all products.

Viewing 10 replies - 1 through 10 (of 10 total)
  • The topic ‘Wrong price for some products’ is closed to new replies.