• Resolved mikey93

    (@mikey93)


    Dear all

    We’ve 2 currencies in use (CHF / EUR) and now we’ve activated the guest mode.

    Depending from WHO the first visitor is visiting the website, it saves CHF prices or EUR prices for first visit. This is not good.

    Is there a possibility to define 2 guest mode versions, 1x for Swiss visitors, 1x for EU visitors?

    We use WPML and Multicurrency by WPML.

Viewing 11 replies - 1 through 11 (of 11 total)
  • Plugin Support qtwrk

    (@qtwrk)

    please provide the report number , you can get it in toolbox -> report -> click “send to LiteSpeed”

    Thread Starter mikey93

    (@mikey93)

    RIMZLXCL

    Plugin Support qtwrk

    (@qtwrk)

    you enabled GeoIP module ?

    do you see GeoIP info in phpinfo page?

    Thread Starter mikey93

    (@mikey93)

    Yes, the GeoIP is enabled server-side (but as well in the backend in WooCommerce>Settings>MaxMind)

    Plugin Support qtwrk

    (@qtwrk)

    okay so I assume Switzerland go for CHF , and rest of world goes for EUR?

    Thread Starter mikey93

    (@mikey93)

    Exactly, Switzerland = CHF, all the rest of the EU = EUR

    Plugin Support qtwrk

    (@qtwrk)

    <IfModule LiteSpeed>
    GeoIPEnable On
    RewriteEngine On
    RewriteCond %{ENV:GEOIP_COUNTRY_CODE} CH [NC]
    RewriteRule .* - [E=Cache-Control:vary=%{ENV:LSCACHE_VARY_VALUE}+isCHF]
    RewriteCond %{ENV:GEOIP_COUNTRY_CODE} !CH [NC]
    RewriteRule .* - [E=Cache-Control:vary=%{ENV:LSCACHE_VARY_VALUE}+isEUR]
    </IfModule>

    please try add this at top of your .htaccess and purge all.

    Thread Starter mikey93

    (@mikey93)

    
    GeoIPEnable On RewriteEngine On RewriteCond %{ENV:GEOIP_COUNTRY_CODE} CH [NC] RewriteRule .* - [E=Cache-Control:vary=%{ENV:LSCACHE_VARY_VALUE}+isCHF] RewriteCond %{ENV:GEOIP_COUNTRY_CODE} !CH [NC] RewriteRule .* - [E=Cache-Control:vary=%{ENV:LSCACHE_VARY_VALUE}+isEUR] BEGIN LSCACHE LITESPEED WP CACHE PLUGIN - Do not edit the contents of this block!
    
    
    RewriteEngine on
    CacheLookup on
    RewriteRule .* - [E=Cache-Control:no-autoflush]
    RewriteRule .litespeed_conf.dat - [F,L] marker ASYNC start
    
    RewriteCond %{REQUEST_URI} /wp-admin/admin-ajax.php
    RewriteCond %{QUERY_STRING} action=async_litespeed
    RewriteRule .* - [E=noabort:1] marker ASYNC end marker MOBILE start
    
    RewriteCond %{HTTP_USER_AGENT} Mobile|Android|Silk/|Kindle|BlackBerry|Opera\ Mini|Opera\ Mobi [NC]
    RewriteRule .* - [E=Cache-Control:vary=%{ENV:LSCACHE_VARY_VALUE}+ismobile] marker MOBILE end marker NOCACHE COOKIES start
    
    RewriteCond %{HTTP_COOKIE} \$wcml_custom_currency_cookie|wcml_custom_currency_cookie
    RewriteRule .* - [E=Cache-Control:no-cache] marker NOCACHE COOKIES end marker CACHE RESOURCE start
    
    RewriteRule wp-content/./[^/](responsive|css|js|dynamic|loader|fonts).php - [E=cache-control:max-age=3600] marker CACHE RESOURCE end marker FAVICON start
    
    RewriteRule favicon.ico$ - [E=cache-control:max-age=86400] marker FAVICON end marker DROPQS start
    
    CacheKeyModify -qs:fbclid
    CacheKeyModify -qs:gclid
    CacheKeyModify -qs:utm*
    CacheKeyModify -qs:_ga marker DROPQS end LITESPEED WP CACHE PLUGIN - Do not edit the contents of this block! END LSCACHE BEGIN NON_LSCACHE LITESPEED WP CACHE PLUGIN - Do not edit the contents of this block! marker BROWSER CACHE start
    
    
    ExpiresActive on
    ExpiresByType application/pdf A31557600
    ExpiresByType image/x-icon A31557600
    ExpiresByType image/vnd.microsoft.icon A31557600
    ExpiresByType image/svg+xml A31557600
    
    ExpiresByType image/jpg A31557600
    ExpiresByType image/jpeg A31557600
    ExpiresByType image/png A31557600
    ExpiresByType image/gif A31557600
    ExpiresByType image/webp A31557600
    
    ExpiresByType video/ogg A31557600
    ExpiresByType audio/ogg A31557600
    ExpiresByType video/mp4 A31557600
    ExpiresByType video/webm A31557600
    
    ExpiresByType text/css A31557600
    ExpiresByType text/javascript A31557600
    ExpiresByType application/javascript A31557600
    ExpiresByType application/x-javascript A31557600
    
    ExpiresByType application/x-font-ttf A31557600
    ExpiresByType application/x-font-woff A31557600
    ExpiresByType application/font-woff A31557600
    ExpiresByType application/font-woff2 A31557600
    ExpiresByType application/vnd.ms-fontobject A31557600
    ExpiresByType font/ttf A31557600
    ExpiresByType font/otf A31557600
    ExpiresByType font/woff A31557600
    ExpiresByType font/woff2 A31557600 marker BROWSER CACHE end LITESPEED WP CACHE PLUGIN - Do not edit the contents of this block! END NON_LSCACHE BEGIN NITROPACK END NITROPACK @HCP_END@
    
    AddType application/x-font-ttf ttf
    AddType 'image/svg+xml' svg
    
    Options '+Indexes'
    IndexOptions -FancyIndexing The directives (lines) between "BEGIN WordPress" and "END WordPress" are dynamically generated, and should only be modified via WordPress filters. Any changes to the directives between these markers will be overwritten.
    
    RewriteEngine On RewriteBase / RewriteRule ^index.php$ - [L] RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule . /index.php [L] @HCP_END@ Anything after the comment above is left alone Wordfence WAF
    
    Require all denied Order deny,allow Deny from all END Wordfence WAF BEGIN WP CERBER GROOVE END WP CERBER GROOVE
    
    SubstituteMaxLineLength 10M
    
    Header set Access-Control-Allow-Origin “*” BEGIN WordPress Die Anweisungen (Zeilen) zwischen ?BEGIN WordPress“ und ?END WordPress“ sind dynamisch generiert und sollten nur über WordPress-Filter ge?ndert werden. Alle ?nderungen an den Anweisungen zwischen diesen Markierungen werden überschrieben.
    
    RewriteEngine On RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}] RewriteBase / RewriteRule ^index.php$ - [L] RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule . /index.php [L] END WordPress

    I see Wordfence and Nitropack things, we don’t use them?

    May you can help with correct file?

    Plugin Support qtwrk

    (@qtwrk)

    the rule is kind of mess up in format , please try paste it in https://pastebin.ubuntu.com/

    Thread Starter mikey93

    (@mikey93)

    Plugin Support qtwrk

    (@qtwrk)

    hm? I didn’t see any wordfence or nitro ?

Viewing 11 replies - 1 through 11 (of 11 total)
  • The topic ‘Guest mode – EUR / CHF’ is closed to new replies.