Waiting for author
Overview of the issue
When using LiteSpeed Cache with WPML Multilingual & Multicurrency for WooCommerce and the multicurrency feature, switching back to the default currency after selecting a secondary currency may not work correctly. The currency remains stuck, and you need to repeat the operation twice to make it work.
Workaround
Please, make sure of having a full site backup of your site before proceeding.
- Add the following code to your theme’s functions.php file.
// WPML - Use Cookie instead of WCSession add_filter( 'wcml_user_store_strategy', function ( $strategy, $key ) { return 'cookie'; }, 10, 2 ); - Go to to « LiteSpeed Cache > Cache > Advanced > Vary Cookies« .
- Add the following cookie:
wcml_client_currency