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

Rounding Syntax

šŸŽ„ Holiday Notice - Support Vacation šŸŽ„

ATTENTION: From December 28, 2025 to January 6, 2026 our support team will be on vacation.

Important information:

  • āŒ No ticket responses from December 28 to January 6
  • āœ… Support will resume on January 7, 2026
  • šŸ“ You can still submit tickets during vacation - they will be queued and answered starting January 7
  • āš ļø Urgent technical issues: Please check our documentation and codex first

šŸŽ… Season's Greetings! šŸŽ…

We want to thank all our amazing customers for your trust and support throughout 2025!
Merry Christmas and Happy New Year to you and your families! šŸŽ‰

We wish you:

  • šŸš€ Successful online stores
  • šŸ’° Growing sales
  • 😊 Happy customers
  • šŸŽÆ Achieved goals in 2026

Thank you for being with us! We appreciate every one of you and look forward to continuing our work together in the new year.

Rest, recharge, and see you in 2026!

Best regards,
PluginUs.Net Team

The support doesn work on Saturdays and Sundays, so some Friday requests can be answered on Monday. If you have problems with registration ask help on contact us page please
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.

Hello.

 

How can I edit the syntax for WOOBE to round differently than what is built in? I would like to round my prices in increments of 5 euros (5.00, 10.00, 15.00, 20.00, 425.00 Euros and so on) and in increments of 1 euros (1.00, 45.00, 32.00, 19.00 Euros). I found this in the domcumentation:

2
3
4
add_filter('woobe_number_field_manipulation', function($value, $field_key, $product_id) {
Ā Ā Ā Ā //write your logic here
Ā Ā Ā Ā return $value;
}, 10, 3);

But I do not know the syntax for the logic. Could I add these to the dropdown menu of the price rounding? Where there's 5, 99, 39 and so on to add 2 extra buttons? 500 and 100?

 

Thank you!

Hello

readĀ  thisĀ  please - https://stackoverflow.com/questions/4133859/round-up-to-nearest-multiple-of-five-in-php

Could I add these to the dropdown menu of the price rounding? - Unfortunately, the plugin does not have such a feature, you need customization of the code

Ok, I see about the dropdown menu. But I am not fluent in php.

I would like to use the woobe_number_field_manipulation hook mentioned on this page of the documentation: https://bulk-editor.com/document/woocommerce-price-rounding/

How do I round to 5s or 1s with that? I know about the ceil and round functions, but what arguments should I round with these functions? Could you please help me out with this?

 

Thank you!

Hello

YouĀ  canĀ  add thisĀ  codeĀ  in functions.phpĀ  ( Keep in mind I have not tested this code. )

add_filter('woobe_number_field_manipulation',Ā function($value,Ā $field_key,Ā $product_id)Ā {
Ā if($field_key=='sale_price' OR $field_key=='regular_price'){
 return (round($value)%5 === 0) ? round($value) : round(($value+5/2)/5)*5;
Ā }
Ā Ā Ā Ā returnĀ $value;
},Ā 10,Ā 3);