Skip to content
Advertisement

Round up cart total Woocommerce

I need to round up prices on my Woocommerce cart. It rounds up to 1. For example:

If the total price of the cart is $40.85, I need the cart to show $41.00.

I tried with this command but the price discount this 0.15 and I do not know how to do it. I found this in other sites but round up the products in the catalog.

JavaScript

Thanks for your help.

Advertisement

Answer

I believe this is what you’re looking for. This will round your cart total to the next dollar. You can also use WooCommerce settings to round displayed product prices before items are added to the cart.

JavaScript
User contributions licensed under: CC BY-SA
7 People found this is helpful
Advertisement