Support Forum

Content of the article

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

Rounding aproximate price, value and shipping rates

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 green button on the right side) and press Save button.
If you not got email within 24 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 ,

I am using Show aprox. Price and Amount options.
Is it possible to round the last full digit to zero same as for the raw and variable price for which I am using the following code:

global $WOOCS;

if($WOOCS->current_currency=="RUB") {

add_filter('woocs_raw_woocommerce_price', function($price) {

if (($price <= 10))

{

$price = round($price / 10, 0) * 10;

return $price;

} else

{

$price = ceil($price/10) * 10;

return $price;

}

});}

 

Also for the shipping cost to round the last full digit to zero.

Thanks,

Marko

Hello Marko

You  need  to customize  plugin code

In file - \wp-content\plugins\woocommerce-currency-switcher\classes\woocs_after_33.php  in  function woocs_add_approx_to_price