FOX - Currency Switcher for WooCommerce

WooCommerce Extra Product Options (by themecomplete)

Plugin link: https://codecanyon.net/item/woocommerce-extra-product-options/7908619
  • In file wp-content\plugins\woocommerce-tm-extra-product-options\include\classes\class-tm-epo-cart.php add next code:
    if (class_exists('WOOCS')) {
        global $WOOCS;
        if ($WOOCS->is_multiple_allowed AND $price1) {
            $currrent = $WOOCS->current_currency;
            if ($currrent != $WOOCS->default_currency) {
                $currencies = $WOOCS->get_currencies();
                $rate = $currencies[$currrent]['rate'];
                $price1 = $price1 / $rate;
            }
        }
    }
    
  •  In file wp-content\plugins\woocommerce-tm-extra-product-options\assets\js\tm-epo.js add next code:
    if (typeof woocs_current_currency != 'undefined') {
        data.symbol = woocs_current_currency['symbol'];
        data.precision = woocs_current_currency['decimals'];
    }
    
  • And check option in this plugin:
    WooCommerce Extra Product Options (by themecomplete)WooCommerce Extra Product Options (by themecomplete)WooCommerce Extra Product Options (by themecomplete)WooCommerce Extra Product Options (by themecomplete)WooCommerce Extra Product Options (by themecomplete)WooCommerce Extra Product Options (by themecomplete)WooCommerce Extra Product Options (by themecomplete)WooCommerce Extra Product Options (by themecomplete)WooCommerce Extra Product Options (by themecomplete)WooCommerce Extra Product Options (by themecomplete)WooCommerce Extra Product Options (by themecomplete)WooCommerce Extra Product Options (by themecomplete)
  • To file wp-content\plugins\woocommerce-tm-extra-product-options\include\classes\class-tm-epo-cart.php add next code:
    if (class_exists('WOOCS') AND isset($cart_item['tm_epo_product_original_price']) AND $cart_item['tm_epo_product_original_price']) {
        global $WOOCS;
        $cart_item['tm_epo_product_original_price'] = $WOOCS->woocs_exchange_value(floatval($cart_item['tm_epo_product_original_price']));
    }
    
  • On the same file add next code:
    if (class_exists('WOOCS') AND isset($cart_item['tm_epo_product_original_price']) AND $cart_item['tm_epo_product_original_price']) {
        global $WOOCS;
        $cart_item['tm_epo_product_original_price'] = $WOOCS->woocs_exchange_value(floatval($cart_item['tm_epo_product_original_price']));
    }
    
  • In file wp-content\plugins\woocommerce-tm-extra-product-options\includes\classes\class-themecomplete-epo-order.php comment next:
  • in file wp-content\plugins\woocommerce-tm-extra-product-options\admin\class-themecomplete-epo-admin-base.php comment next code:
This edit is inside another plugin's file, so a plugin update will undo it. Write the change down, and re-apply it after every update of that plugin — or ask its authors to include the fix on their side, which is the only version that survives. If the change is inside FOX itself, tell us: a fix that has to be re-applied by hand is a bug on our side, not a solution.