PluginUs.Net - Business Tools for WooCommerce and WordPress

[realize your idea - make your dreams come true]

Support Forum

You need to log-in to create request (topic) to the support

Price Rounding To Zero

This support system is for all types of the plugins as for premium versions, so for free ones! If you have premium version do not forget in the private data of the request (!!not in the text of the support request!!) after its publishing insert purchase code please (see blue-green button on the right side) and press Save button.
If you not got email within 24~36 business hours, firstly check your spam box, and if no any email from the support there - back to the forum and read answer here. DO NOT ANSWER ON EMAILS [noreply@pluginus.net] FROM THE FORUM!! Emails are just for your info, all answers should be published only here.
The support doesn work on Saturdays and Sundays, so some Friday requests can be answered on Monday.

Hi, how can I set price rounding for example $10.12 - $10.00 for all currencies to the closest zero and price display, using the pro version

Hello

Please paste your license key here - https://share.stackovergo.com/image/i20210618130558.png -> https://share.stackovergo.com/image/i20210618130614.png

Read  this  please - https://currency-switcher.com/hook/woocs_raw_woocommerce_price/  and https://currency-switcher.com/hook/woocs_woocommerce_variation_prices/

I picked up my client was only using the free version, so I purchased the paid version, great plugin thanks

I am not sure witch values to use top make the price en with ,00 from your formula is not for 00 cents but 50 or 500 (not even sure what units they are.

add_filter('woocs_raw_woocommerce_price', function($price) {
    return round($price * 2, 0) / 2;
});

Hello

This is just a sample code

Try to use:

return round((float)$price );

Hi I tried your code in my function.php file but my prices still show prices with unrounded cents

add_filter('woocs_raw_woocommerce_price', function($price) {
return round((float)$price );
});

https://presidential.co.za/product/ndebele-check-rayon-short-sleeve-revere-collar-mens-shirt/ any suggestions

please  read  my  messages - https://c2n.me/4e6BeYe.png

Add  the  same  code  for  - woocs_woocommerce_variation_prices

Awesome thank you, that set my prices to zero cents, thank  you very much.

To make this easier for the next guy, simply add this to your functions.php folder

add_filter('woocs_raw_woocommerce_price', function($price) {
return round((float)$price );
});
add_filter('woocs_woocommerce_variation_prices', function($price) {
return round((float)$price );
});

Best Regards and Thanks

Welcome;)