Skip Navigation

This is the technical support forum for WPML - the multilingual WordPress plugin.

Everyone can read, but only WPML clients can post here. WPML team is replying on the forum 6 days per week, 22 hours per day.

This topic contains 74 replies, has 3 voices.

Last updated by Sumit 7 months, 3 weeks ago.

Assisted by: Sumit.

Author Posts
January 31, 2024 at 12:49 am #15246913

louisN-4

we have 5 languages but - hebrew is the main language of the site

it seems since your last version,

hebrew pages gets served from cache on incognito
while pages in other languages don't

i spoken to litespeed and they also investigate

HE example page: hidden link
EN example page: hidden link

the 2 pages are the same just different language

i need your assistance to figure this please

- we have wpml version 4.6.9
- litespeed 6.0

January 31, 2024 at 2:16 pm #15249767

Bigul
Supporter

Languages: English (English )

Timezone: Europe/Vienna (GMT+01:00)

Hello,

Welcome to the WPML support forum. I will do my best to help you to resolve the issue.

I checked it here in Google Chrome Incognito mode during the busy internet hours of our time. Both the Hebrew and English posts show similar loading times for me.

Please check the attached images for more details and let us know your feedback.

Have you received any feedback from the LiteSpeed team?

--
Thanks!

Bigul

2024-01-31_19h35_09.png
2024-01-31_19h22_24.png
January 31, 2024 at 11:40 pm #15252375

louisN-4

i stand behind what i said - and i checked now

HE example page: CACHED
hidden link

EN example page: NOT CACHED
hidden link

but i guess i need to give you a deeper explanation

litespeed asked that we add to litespeed htaccess

<IfModule LiteSpeed>
RewriteRule .? - [E=Cache-Vary:client_currency_cookie]
</IfModule>

which we did, and indeed after the first entrance to the site, the cache works perfectly.

BUT what is odd, is that Hebrew pages gets cache hit as i have shown above, and other (secondary) languages, are never HIT (=MISS) but after the page load, if i try to go to other pages on the site they most likely a hit.

It seems something related to secondary languages - litespeed suggest some kind of rule
this is what they wrote
"you may need that rule to make the currency or language to work properly"

we do have from you also snippet you gave us in the past related to ?currency=XXX

but since even without ?currency=XXX things are slow on first entrance, i guess it could be WPML code related issue with cookies and litespeed

by the way, adding the below code to WPML website, is definitely welcome
<IfModule LiteSpeed>
RewriteRule .? - [E=Cache-Vary:client_currency_cookie]
</IfModule>

because after you enter the site, things are super fast,

but they are super fast also on hebrew if the page was cached already, so i don't understand why only for /en/ /ru/ /de/ /nl/
things are slow on the first access only

since you know WPML by far better than me, maybe its worth first to look at dev console and maybe you will see different cookies on the secondary languages than on the main language (hebrew) and maybe you would know what is going little sideways

February 1, 2024 at 6:05 pm #15256340

Bigul
Supporter

Languages: English (English )

Timezone: Europe/Vienna (GMT+01:00)

Hello,

Thank you for the feedback. I am consulting with our team for an expert opinion on this. We will get back to you as soon as possible. Please wait.

--
Thanks!

Bigul

February 1, 2024 at 10:09 pm #15257124

louisN-4

i spoke to litespeed today

they claim that normally every entrance should be a miss unless you created a rule for that,
and it seems you did create a rule for it in the master language but for the secondary languages, you didn't

if you speak to litespeed about it the ticket numbers are:
103817 and 558213

I have another hypnosis, because Hebrew doesn’t have several currencies,
It works straight with cache.

February 2, 2024 at 12:06 am #15257242

louisN-4

I tend to think my "hypothesis" is accurate

"because Hebrew doesn’t have several currencies,
It works straight with cache."

and if i am right, then it would be an easy wpml fix to solve this other languages with extra snippet or code fix, that if loaded without ?currency=XXX

then it should somehow not transmit that it needs special cookie for currency like the hebrew and use that language main default currency

February 2, 2024 at 6:24 pm #15260770

Bigul
Supporter

Languages: English (English )

Timezone: Europe/Vienna (GMT+01:00)

Hello,

Thank you for the updates. For your kind attention, you are currently using a very old version of WooCommerce and WooCommerce Multilingual plugins.

Since the version 5.1.2 of WooCommerce Multilingual, we introduced most of the performance fixes and improvements on it. In this case, we would really advise trying the latest version 5.3.3.1, the latest version. It has lot of fixes. Please check the change log for more details.

https://wpml.org/download/woocommerce-multilingual-multicurrency/?section=changelog

Therefore it would be great if you could try it on your staging site (a clone copy of the live site) to confirm whether it resolves the issues or not. Please check and let us know your feedback.

--
Thanks!

Bigul

February 2, 2024 at 6:34 pm #15260788

louisN-4

Hello Bigul,

I don't like to be a rat lab

i checked your changelog, and i didn't see any fix related to litespeed since my version

1. either you are lurcing in the dark
2. OR you didn't write in the changelog in related to litespeed fix to what i was showing you.

A. is my hypothesis correct, that hebrew works fast because it doesn't hav multi currency?
B. Did you check with litespeed how to make all languages work fast even with multi currency so is cached?
C. AT LAST after we resolve it, i will need your assistance to modify the ?currency=XXX you gave me in the past, so its cached as well

THIS IS THE LATEST FROM LITESPEED on ticket: 558213
- and it does seem like a collaboration bug between litespeed and wpml that needs to be addressed !

and in order to properly display the currency and language , the cookie must be set

and in order to set cookie , the PHP must be triggered

and in order to trigger the PHP , the cache must be missed as cache hit will avoid launch PHP process.

I have had this conversation with WPML team some times ago , and attempt to find a solution to make first visit cache hit with multi-language/currency , believe me , we spent a lot of time and effort to it , but unfortunately we can't find a good solution for such

February 4, 2024 at 8:14 am #15263111

Bigul
Supporter

Languages: English (English )

Timezone: Europe/Vienna (GMT+01:00)

Hello,

Thank you for your feedback. I have shared it with our team. Please note that the last major release of WooCommerce Multilingual is 5.3. Rest of the releases are fixes and improvements.

We request to upgrade to you to the latest version in a staging site to make sure the bug exists with the latest versions or not. As you know, the backward compatibility is very very tough to implement.

We will get back to you on this soon. Please wait.

--
Thanks!

Bigul

February 4, 2024 at 10:12 am #15263265

louisN-4

i think you missed this message from litespeed:

"I have had this conversation with WPML team some times ago , and attempt to find a solution to make first visit cache hit with multi-language/currency , believe me , we spent a lot of time and effort to it , but unfortunately we can't find a good solution for such"

February 4, 2024 at 10:51 pm #15264059

louisN-4

and i need to stress again

HE example page: CACHED
hidden link

EN example page: NOT CACHED
hidden link

Hebrew gets cached, others don't, this is whats WPML needs to figure out why

1. it could be how you treat the main language that is working correctly and secondary not
2. OR i could be that because HE has 1 currency while others have multiple

but even if its 2, you found via 1 the way to make the first hit of 2 gets cached if you fix the code together with litespeed

February 5, 2024 at 4:22 pm #15267305

Bigul
Supporter

Languages: English (English )

Timezone: Europe/Vienna (GMT+01:00)

Hello,

Thank you for providing us with the details. I've forwarded them to our second-tier team for further investigation. We'll update you soon. Please wait.

--
Thanks!

Bigul

February 6, 2024 at 5:18 pm #15273277

Bigul
Supporter

Languages: English (English )

Timezone: Europe/Vienna (GMT+01:00)

Hello,

We have found the ticket LiteSpeed team has mentioned. Our compatibility team were in touch with them and we had a detailed debugging on this in the past. As per our their last communication, they were working on a solution for this. Please check the following replies for more details.

https://wpml.org/forums/topic/follow-up-to-site-language-resetting-the-cache/page/2/#post-12922031

https://wpml.org/forums/topic/follow-up-to-site-language-resetting-the-cache/page/2/#post-13035833

So as of now there is no proper workaround for this other than disabling the Multi Currency feature. Thank you for your kind understanding.

--
Thanks!

Bigul

February 6, 2024 at 6:57 pm #15273567

louisN-4

today i gave litespeed supporter to copy my site to his server, so he can explore a fix to this

February 7, 2024 at 4:53 am #15274289

Bigul
Supporter

Languages: English (English )

Timezone: Europe/Vienna (GMT+01:00)

Hello,

Thank you for the feedback. Hoping for the best outcome. We will wait for your updates.

--
Thanks!

Bigul