My site is a woocommerce store with multi-currency (through CURCY – WooCommerce Multi Currency Premium ) and multi-language (through WPML).
My purpose is to maintain cache for a week, after first visitor, all subsequent visitors with the same language and currency, and with an empty cart, should share the same cached version.
CacheVary wp-wpml_current_language,wmc_current_currency
RewriteCond %{HTTP_COOKIE} !woocommerce_cart_hash=[^;]+
RewriteRule .* - [E=Cache-Control:vary=wmc_current_currency]
My purpose is to maintain cache for a week, after first visitor, all subsequent visitors with the same language and currency, and with an empty cart, should share the same cached version.
CacheVary wp-wpml_current_language,wmc_current_currency
RewriteCond %{HTTP_COOKIE} !woocommerce_cart_hash=[^;]+
RewriteRule .* - [E=Cache-Control:vary=wmc_current_currency]