Plugin link: https://pluginrepublic.com/wordpress-plugins/woocommerce-product-add-ons-ultimate/ In file plugins\product-extras-for-woocommerce\inc\functions-cart.php add next code:
| if (class_exists('WOOCS')) { global $WOOCS; if ($WOOCS->is_multiple_allowed) { $price = $WOOCS->woocs_exchange_value(floatval($price)); } } |
On the same file add next code:
| if (class_exists('WOOCS') AND $price) { global $WOOCS; if ($WOOCS->is_multiple_allowed) { $currrent = $WOOCS->current_currency; if ($currrent != $WOOCS->default_currency) { $currencies = $WOOCS->get_currencies(); $rate = $currencies[$currrent]['rate']; $price = $final_price / $price; } } } |
And to the same file:
| if (class_exists('WOOCS')) { global $WOOCS; if ($WOOCS->is_multiple_allowed AND isset($cart_item_data['product_extras']['price_with_extras'])) { $currrent = $WOOCS->current_currency; if ($currrent != $WOOCS->default_currency) { $currencies = $WOOCS->get_currencies(); $rate = $currencies[$currrent]['rate']; $cart_item_data['product_extras']['price_with_extras'] = $cart_item_data['product_extras']['price_with_extras'] / $rate; } } } |
And on the same file:
| if (class_exists('WOOCS')) { global $WOOCS; if ($WOOCS->is_multiple_allowed) { $currrent = $WOOCS->current_currency; if ($currrent != $WOOCS->default_currency) { $currencies = $WOOCS->get_currencies(); $rate = $currencies[$currrent]['rate']; $cart_item_data['product_extras']['price_with_extras_discounted'] = $cart_item_data['product_extras']['price_with_extras_discounted'] / $rate; } } } |
And on the same file:
| if (class_exists('WOOCS') AND $item['price']) { global $WOOCS; if ($WOOCS->is_multiple_allowed) { $currrent = $WOOCS->current_currency; if ($currrent != $WOOCS->default_currency) { $currencies = $WOOCS->get_currencies(); $rate = $currencies[$currrent]['rate']; $item['price'] = $rate * $item['price']; } } $item['value'] = preg_replace('/\((.+)\)/', "", $item['value']); $item['value'] .= sanitize_text_field("(" . wc_price($item['price']) . ")"); } |
Plugin link: https://codecanyon.net/item/aliexpress-dropship-for-woocommerce/19821022 Producer: https://ali2woo.com/ In file \plugins\ali2woo\includes\classes\shipping\A2W_ShippingFrontendPageController.php add next code:
| if (class_exists('WOOCS') AND $method['price'] > 0) { global $WOOCS; $method['price'] = $WOOCS->woocs_exchange_value(floatval($method['price'])); } |
Also to the same file add next code:
| if (class_exists('WOOCS') AND $method['price'] > 0) { global $WOOCS; $method['price'] = $WOOCS->woocs_exchange_value(floatval($method['price'])); } |
Plugin link: https://codecanyon.net/item/wootour-woocommerce-travel-tour-and-appointment-booking/19404740 In file \plugins\woo-tour\inc\functions.php add next code:
| if (class_exists('WOOCS')) { global $WOOCS; if ($WOOCS->is_multiple_allowed) { $price = $WOOCS->woocs_exchange_value(floatval($price)); } } |
In file plugins\woo-tour\inc\class-woo-booking.php add next code:
| }else if (class_exists('WOOCS')){ global $WOOCS; $currency = $WOOCS->current_currency; if ($WOOCS->is_multiple_allowed) { $currencies = $WOOCS->get_currencies(); $def_curr = $WOOCS->default_currency; if ($cart_object->cart_contents[$key]['_crc_when_book']!=$def_curr) { $conversion_rate = $currencies[$cart_object->cart_contents[$key]['_crc_when_book']]['rate']; $pr_b = $pr_b / $conversion_rate; $cart_object->cart_contents[$key]['_crc_when_book'] = $def_curr; } } }; |
And to the same file:
| }else if(class_exists('WOOCS')){ global $WOOCS; $currency = $WOOCS->current_currency; $cart_object->cart_contents[$key]['_crc_when_book'] = $currency; } |
Plugin link: https://codecanyon.net/item/ultimate-affiliate-pro-wordpress-plugin/16527729 In file \wp-content\plugins\indeed-affiliate-pro\public\services\Uap_Woo.class.php add next code:
| //woocs $curr = $order->get_order_currency(); if (class_exists('WOOCS')) { global $WOOCS; if ($curr != $WOOCS->default_currency) { $currencies = $WOOCS->get_currencies(); $sum = $WOOCS->back_convert($sum, $currencies[$curr]['rate']); } } |
Note: This will only work with new orders
Plugin link: https://codecanyon.net/item/sumo-affiliates-pro-wordpress-affiliate-plugin/22795996 In file wp-content\plugins\affs\inc\woocommerce\class-fs-affiliates-wc-commission.php add next code:
| if (class_exists('WOOCS')) { global $WOOCS; if ($WOOCS->is_multiple_allowed) { $currrent = $WOOCS->current_currency; if ($currrent != $WOOCS->default_currency) { $currencies = $WOOCS->get_currencies(); $rate = $currencies[$currrent]['rate']; $RegularPrice = $RegularPrice / $rate; } } } |
Plugin link: https://woocommerce.com/products/woocommerce-deposits/ In file \wp-content\plugins\woocommerce-deposits\includes\class-wc-deposits-cart-manager.php add next code:
| if (class_exists('WOOCS')) { global $WOOCS; if ($WOOCS->is_multiple_allowed) { $currrent = $WOOCS->current_currency; if ($currrent != $WOOCS->default_currency) { $currencies = $WOOCS->get_currencies(); $rate = $currencies[$currrent]['rate']; $total = $total / $rate; } } } |
On the same file add nex code:
| if (class_exists('WOOCS')) { global $WOOCS; if ($WOOCS->is_multiple_allowed) { $currrent = $WOOCS->current_currency; if ($currrent != $WOOCS->default_currency) { $currencies = $WOOCS->get_currencies(); $rate = $currencies[$currrent]['rate']; $total = $total / $rate; } } } |
In file functions.php of the current wordpress theme add next code:
| add_filter('woocommerce_deposits_get_deposit_amount', function ($deposit, $prod) { if (class_exists('WOOCS')) { global $WOOCS; $currrent = $WOOCS->current_currency; if ($currrent != $WOOCS->default_currency AND $WOOCS->is_multiple_allowed) { $currencies = $WOOCS->get_currencies(); $rate = $currencies[$currrent]['rate']; $deposit = $deposit * $rate; } } return $deposit; }, 2, 99); |
Plugin link: https://wordpress.org/plugins/woocommerce-role-based-price/ In file functions.php of the current wordpress theme add next code:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 | add_filter("wc_rbp_product_get_price", function($wcrbp_price, $product, $rbp_this) { if (class_exists('WOOCS')) { $sale_price = $product->get_sale_price(); global $WOOCS; if ($WOOCS->is_multiple_allowed AND ( $sale_price !== '' && $sale_price > 0 )) { $currrent = $WOOCS->current_currency; if ($currrent != $WOOCS->default_currency) { $currencies = $WOOCS->get_currencies(); $rate = $currencies[$currrent]['rate']; $wcrbp_price = $wcrbp_price / $rate; } } } return $wcrbp_price; }, 99, 3); |
In file wp-content\plugins\woocommerce-role-based-price\includes\class-product-pricing.php add next code:
| if (class_exists('WOOCS')) { global $WOOCS; if ($WOOCS->is_multiple_allowed) { $prices['min_price'] = $WOOCS->woocs_exchange_value(floatval($prices['min_price'])); $prices['max_price'] = $WOOCS->woocs_exchange_value(floatval($prices['max_price'])); $prices['min_reg_price'] = $WOOCS->woocs_exchange_value(floatval($prices['min_reg_price'])); $prices['max_reg_price'] = $WOOCS->woocs_exchange_value(floatval($prices['max_reg_price'])); } } |
In file \wp-content\plugins\woocommerce-role-based-price\includes\class-product-pricing.php change code:
| if( $is_hook == TRUE OR (class_exists('WOOCS') AND defined( 'DOING_AJAX' )) ) { |
Note: unfortunately this does not work with option “I am using cache plugin on my site”
Plugin link: https://discountsuiteforwp.com/woocommerce-bulk-discounts/ In file \wp-content\plugins\woocommerce-all-discounts\includes\class-wad.php make changes as shown on the screen:
Plugin link: https://yithemes.com/themes/plugins/yith-woocommerce-account-funds/ In file \wp-content\plugins\yith-woocommerce-account-funds-premium\includes\class.yith-ywf-deposit-fund-checkout.php add next code:
| if (class_exists('WOOCS')) { global $WOOCS; if ($WOOCS->is_multiple_allowed) { $currrent = $WOOCS->current_currency; if ($currrent != $WOOCS->default_currency) { $currencies = $WOOCS->get_currencies(); $rate = $currencies[$currrent]['rate']; $amount = $amount / $rate; } } } |
In file \wp-content\plugins\yith-woocommerce-account-funds-premium\includes\class.yith-ywf-customer.php add next code (twice as on the image below):
| if (class_exists('WOOCS')) { global $WOOCS; if ($WOOCS->current_currency != $WOOCS->default_currency) { $currencies = $WOOCS->get_currencies(); $new_funds = $new_funds / $currencies[$WOOCS->current_currency]['rate']; } } |
In file \wp-content\plugins\yith-woocommerce-account-funds-premium\includes\class.wc-gateway-yith-funds.php delete next code: In file functions.php of the current wordpress theme add next code:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 | <?php add_filter('yith_show_available_funds', function($fund_av) { if (class_exists('WOOCS')) { global $WOOCS; if ($WOOCS->is_multiple_allowed) { $fund_av = $WOOCS->woocs_exchange_value($fund_av); } } return $fund_av; }); add_filter('yith_show_used_funds', function($fund_av) { if (class_exists('WOOCS')) { global $WOOCS; if ($WOOCS->is_multiple_allowed) { $fund_av = $WOOCS->woocs_exchange_value($fund_av); } } return $fund_av; }); add_filter('yith_min_deposit', function($fund_av) { if (class_exists('WOOCS')) { global $WOOCS; if ($WOOCS->is_multiple_allowed) { $fund_av = floor($WOOCS->woocs_exchange_value($fund_av)); } } return $fund_av; }); add_filter('yith_max_deposit', function($fund_av) { if (class_exists('WOOCS') AND $fund_av) { global $WOOCS; if ($WOOCS->is_multiple_allowed) { $fund_av = ceil($WOOCS->woocs_exchange_value($fund_av)); } } return $fund_av; }); |
Plugin link: https://shop.wanderlust-webdesign.com/shop/woocommerce-andreani-premium-shipping/ Note: 25-09-2020 this fix was implemented by author of the plugin directly into the plugin “WooCommerce Andreani” In file wp-content\plugins\wanderlust-andreani-shipping\includes\class-wc-shipping-andreani.php add next code:
| if (class_exists('WOOCS')) { global $WOOCS; $currencies = $WOOCS->get_currencies(); if (isset($currencies['ARS'])) { $precio = $WOOCS->back_convert($precio, $currencies['ARS']['rate']); } } |
This only works if the base currency is not ARS