WooCommerce Multicurrency (Currency Switcher)
Add multiple currencies (currency switcher) to WooCommerce
Description
When enabled, WooCommerce Multicurrency (Currency Switcher) module adds multicurrency (currency switcher) to your WooCommerce shop.
Options
First you will need to set which currencies you want to add.
- Go to admin options in WooCommerce > Settings > Booster > Prices & Currencies > Multicurrency
- Then go to Currency Options, set number of Total Currencies and press Save changes button. Please note that you will probably need to add current (original) shop currency here (with an exchange rate of 1), so most likely minimum number here should be set to at least 2.
- Then choose currencies you want to add from drop down lists and set exchange rates for each currency. Rates can be set to update automatically or manually.
- If you prefer setting price in each currency on per product basis (instead of using automatic price calculation by exchange rates) – enable Multicurrency on per Product Basis checkbox and go to product edit page.
General Options
- Exchange Rates Updates
- Select how you want currency exchange rates to be updated. Possible options are: manually or automatically via Currency Exchange Rates module.
- Default:
Enter Rates Manually
- Default:
- Multicurrency on per Product Basis
- If you enable this option, you will be able to enter prices for products in different currencies directly (i.e. without exchange rates). This will add meta boxes in product edit.
- Default:
yes
- Default:
- Revert Currency to Default on Checkout
- Enable this if you want prices to revert back to your shop’s default currency, when customer reaches the checkout page.
- Default:
no
- Default:
- Rounding
- If using exchange rates, choose rounding here.
- Default:
No rounding
- Default:
- Rounding Precision
- If rounding is enabled, set rounding precision here.
- Default:
- Default:
- Currency Switcher Template
- Set how you want currency switcher to be displayed on frontend. Replaced values:
%currency_name%
,%currency_symbol%
,%currency_code%
.- Default:
%currency_name% (%currency_symbol%)
- Default:
- Advanced: Additional Price Filters
- Add additional price filters here. One per line. Leave blank if not sure. E.g.:
woocommerce_subscriptions_product_price
,woocommerce_get_price
.- Default: None
Currencies Options
- Total Currencies
- Set total number of currencies here. One currency probably should be set to current (original) shop currency with an exchange rate of 1. Press Save changes after setting this option, so new settings fields will be added.
- Default:
- Default:
- Currency #X
- Here you can select which currency you want to add. Also, in case if you selected “Enter Rates Manually”, you can set exchange rate here. In case of automatic updates, rate will be updated automatically. You can also grab current exchange rate by pressing button near the exchange rate field.
- Default: Shop’s default currency with exchange rate 1
Role Defaults
This section lets you set default currency for user role. Leave blank to disable.
Currency Switcher
After setting currencies in the Currencies Options, you can use either Booster – Multicurrency Switcher widget, or one of the shortcodes:
United States (US) dollar ($)
United Arab Emirates dirham (د.إ)
Euro (€)
Brazilian real (R$)
Chinese yuan (¥)
Or if you want to insert switcher in your PHP code, just use:
echo do_shortcode( '' );
Drop down currency selector should look like this on frontend:
If you want to place currency selector near the price, you could use Product Info Module – WooCommerce > Settings > Booster > Products > Product Info – and add shortcode there.You can add currency switcher as a custom link with URL
/?wcj-currency=EUR
etc.You may want to put switcher shortcode in text widget – you can enable shortcodes in WordPress text widgets in Booster’s General module (in “WooCommerce > Settings > Booster > Emails & Misc. > General”) with “Enable All Shortcodes in WordPress Text Widgets” checkbox.If you want to hide/show switcher for certain user roles, you can use visibility
common attribute (which can be used for any Booster’s shortcode). For example, if you want switcher to be visible to administrator
and customer
user roles only, use:
By default “Multicurrency (Currency Switcher)” module is run after the “Price by User Role” module, so if you are using per product prices in “Multicurrency (Currency Switcher)” module (i.e. aren’t using exchange rates), “Multicurrency (Currency Switcher)” module prices will just overwrite the “Price by User Role” prices. To fix this, you need to change modules priorities so that “Multicurrency (Currency Switcher)” is run before the “Price by User Role” module. There are “Advanced: Price Filters Priority” options in both modules – try setting “Multicurrency (Currency Switcher) > Advanced: Price Filters Priority” to 999
, and “Price by User Role > Advanced: Price Filters Priority” to 1000
Front end view
Accessible through:
- WooCommerce > Settings > Booster > Prices & Currencies > Multicurrency (Currency Switcher)
Tested on WooCommerce 4.0.0 and WordPress 5.3.2Plugin can be downloaded here. If there are any locked fields in the module, you will need to get Booster Plus to unlock them.
WooCommerce Booster ModulesWooCommerce CurrenciesWooCommerce Currency SwitcherWooCommerce MulticurrencyWooCommerce Prices