=== FOX - Currency Switcher Professional for WooCommerce ===
Contributors: RealMag777
Tags: woocommerce, currency, switcher, currency switcher, multi currency
Requires at least: 6.0.0
Tested up to: 7.1
Requires PHP: 7.4
Requires Plugins: woocommerce
Stable tag: 2.5.3
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

FOX is a professional multi-currency plugin for WooCommerce. Add any currency, switch prices in real time, customers pay in their selected currency.

== Description ==

**FOX - Currency Switcher Professional for WooCommerce** (former name: WOOCS) is a flexible multi-currency plugin that allows store visitors to switch product prices between currencies in real time and optionally pay in their selected currency.

FOX is available as a shortcode **[[woocs]](https://currency-switcher.com/shortcode/woocs/)** and as a widget. It supports any currency from the [ISO 4217 active codes list](https://en.wikipedia.org/wiki/ISO_4217#Active_codes).

Latest PHP 8.x – COMPATIBLE!

* [Demo](https://demo.currency-switcher.com/)
* [Documentation / API](https://currency-switcher.com/codex/)
* [FAQ](https://currency-switcher.com/faq/)

---

### Features:

**Representation**
Currency Switcher is available as a widget and works in any widgetized area. The shortcode [woocs] can be inserted anywhere on the site, including the top menu.

**Design**
3 display modes: drop-down, flags, side switcher. Set a flag per currency. Use the built-in Smart Designer to create fully custom drop-down designs.

**Checkout**
Customers can pay in their selected currency (option: "Is multiple allowed").

**Rates**
7+ currency aggregators for automatic rate updates. Manual rate entry is also available. Admin can receive email notifications about rate changes.

**Rates Auto Update**
Hourly, twice daily, daily, weekly, monthly, or custom intervals (5, 15, 30, 45 minutes).

**Price Formatting**
Set decimals count, money sign, sign position, thousand and decimal separators per currency. Hide cents per currency. Supports non-standard currencies including BTC.

**Custom Money Signs**
Create and use your own currency symbols.

**Smart Designer**
Interactive front-end builder for custom multi-currency drop-down switchers. Unlimited designs for different site areas.

**Statistics**
Collects currency switching data (currency, country, time). No personal customer data collected. Order currency statistics also available.

**Currency Visibility**
Set currencies as Public or Private. Private currencies are hidden from switchers and cannot be set via URL.

**Payments Rules**
Show or hide payment gateways on checkout depending on the active currency.

**Welcome Currency**
Set a different default display currency for first-time visitors.

**User Role Pricing**
Set different base-currency prices per user role (loyalty programs, wholesale, etc.).

**GeoIP Rules**
Automatically switch currency based on visitor IP. Per-product country/currency rules. "Checkout by GeoIP rules" forces local currency on purchase.

**Fixed Prices Per Product**
Override rate-based conversion with a fixed price per currency per product.

**Fixed Amounts for Shipping, Coupons, Free Delivery Threshold**
Set per-currency fixed values instead of rate-calculated amounts.

**Approximate Price Display**
Show approximate local currency price near the product price and in cart/checkout (GeoIP + rates mode).

**Cache Plugin Compatibility**
"I am using cache plugin" option ensures correct currency switching on cached sites.

**Order Storage**
Each order is stored in the currency the customer paid (when "Is multiple allowed" is enabled).

**Price Info Icon**
Hover icon near prices showing all currency equivalents.

**Currency Storage Mechanisms**
Session, Transient, Memcached, Redis, FOX Session — choose based on hosting architecture.

**Shortcodes**
[[woocs]](https://currency-switcher.com/shortcode/woocs/) — switcher widget
[[woocs_price]](https://currency-switcher.com/shortcode/woocs_price/) — switchable product price in articles
[woocs_converter] — currency converter widget
[woocs_rates] — currency rates widget
[woocs_show_current_currency] — display current currency
[woocs_show_custom_price] — show custom amount in current currency

**No GET Parameters in URL** (optional)
Switch currency without appending ?currency=USD to links.

**WPML & Polylang**
Switch currency automatically when the site language changes.

**REST API**
[REST API documentation](https://currency-switcher.com/function/rest-api/)

**Wide Developer API**
Hooks and functions for price manipulation, rate logic, and display customization. [Full API docs](https://currency-switcher.com/codex/).

**Compatibility**
Compatible with WPML, Polylang, WooCommerce Products Filter (HUSKY), CTX Feed, RnB Booking, WebToffee Product Feed, Points and Rewards by WP Swings. 95% compatibility with payment gateways in multi-currency mode.

---

== Screenshots ==
1. Currency options


== Changelog ==

= 2.5.3 - 04 September, 2026 =
* Fixed: automatic rate updates never ran on shops with regular REST API
  traffic. The rate update scheduler was hooked to rest_api_init without
  limiting the number of accepted arguments, so WordPress passed the
  WP_REST_Server instance into the method's $reset parameter. Every REST
  request therefore restarted the schedule from the current time and cleared
  the last run marker, which pushed the next run permanently into the future.
  Rates stayed frozen at the values stored before the upgrade. Sites with
  block based cart and checkout, the Store API, page builders or headless
  front ends were affected the most, sites with little or no REST traffic were
  not affected. Reported by Performize.it.

= 2.5.2 - 03 September, 2026 =
* Fixed: currency switching was unreliable when "Currency storage" was set to
  Transient and the option "I am using cache plugin on my site" was enabled.
  In that combination the selected currency could be applied to the prices but
  not to the cart, the checkout totals or the currency switcher itself, so
  different parts of one page could show different currencies.
* Fixed: the selected currency is now applied to requests made by WooCommerce
  Blocks and the Store API, so the block based mini cart, cart and checkout
  render in the visitor's currency.
* Fixed: prices were shown in the shop base currency inside content loaded by
  page builders through the REST API, for example the Bricks side cart and
  Bricks popups.
* Fixed: fee lines (for example custom regional tax or surcharge fees) were not converted 
  when an order was recalculated into another currency in wp-admin — the currency label 
  changed while the fee amount stayed as it was.
* Added: order recalculation on manual currency change can now be customized. 
If a function named woocs_order_recalculated_custom exists on the site, 
the plugin calls it right after an order has been recalculated to another currency 
and before the order is saved, passing the order object, the new currency, 
the previous currency and the exchange rate the order was stored with. 
This makes it possible to override amounts of individual order items, 
for example flat fees that must keep a fixed value in each currency instead 
of being converted by rate. Works with both HPOS and legacy order storage. 
If the function is not declared, behaviour is unchanged.

= 2.5.1 - 27 July, 2026 =
* Fixed: fatal error (infinite loop / memory exhaustion) on the order-received
  and view-order pages when HPOS is disabled

= 2.5.0 - 24 July, 2026 =
* Fixed logic of working: cache site + transient, added localstorage for selection personalization
* Fixed class cron: is_attached() returns false not only when the hook is missing, but also when the stored recurrence differs from the currently configured one. So as soon as those two values disagreed for any reason, every single page request re-attached the event and pushed next a full interval into the future.
* Fixed: order totals could be inflated when saving/editing an order in a currency that uses a comma as the decimal separator (wp-admin order editor)
* Fixed: base currency symbol shown instead of the order currency after saving order items on HPOS

= 2.4.9 - 12 June, 2026 =
* 1 security issue fixed thanks to Nguyen Ba Khanh and Patchstack

= 2.4.8 =
* [https://pluginus.net/support/topic/unable-to-refund-order-invalid-refund-amount](fix about orders refund)

= 2.4.6 =
* Small fixes
* 2 security issues fixed (Patchstack bounty program, reported by Que Thanh Tuan and timomangcut)
* 1 security issue fixed (Wordfence bounty program, reported by Ren Voza)

= 2.4.5 =
* Added hook woocs_sheduler_rates_updated

= 2.4.4 =
* Set of small fixes
* New hook woocs_price_html
* New REST API endpoint

= 2.4.3.1 =
* Small fixes
* Fix related to new coupon creation in WooCommerce

= 2.4.3 =
* Small fixes
* New option: Rate floor/ceil - set min/max rate boundaries per currency to protect against sharp rate fluctuations
* New hook woocs_init_compatibility_woo_subscriptions: enables compatibility with WooCommerce Subscriptions

= 2.4.2.3 =
* 1 security issue fixed (Wordfence bounty program, reported by mikemyers)

= 2.4.2.2 =
* 1 security issue fixed (Wordfence, reported by Arkadiusz Hydzik)

= 2.4.2.1 =
* 1 security issue fixed (Patchstack, reported by Ananda Dhakal)

= 2.4.2 =
* Bunch of small fixes
* Improved code security

= 2.4.1.9 =
* 1 security issue fixed (Wordfence, reported by stealthcopter)

= 2.4.1.8 =
* 1 security issue fixed (Patchstack, reported by Dhabaleshwar Das)
* New feature: update order rates from order edit screen; analytics table data is updated accordingly

= 2.4.1 =
* New storage type: FOX Session
* New function convert_from_to_currency - convert an amount between any two currencies directly

= 2.4.0 =
* Heap of small fixes
* New storage type FOX Session
* New function convert_from_to_currency

== Upgrade Notice ==
Always backup before updating. See full changelog at https://currency-switcher.com/changelog
