Skip to content Skip to sidebar

This thread is resolved. Here is a description of the problem and solution.

Problem:
If you're upgrading your site to PHP 8.3 from PHP 7.4 and encounter a login loop when WPML Multilingual CMS and Share Buttons by AddThis plugins are both activated, this might be due to a conflict between these plugins under PHP 8.3. This issue results in an inline JavaScript block within WPML's script growing uncontrollably, causing the site to run out of memory.
Solution:
We recommend deactivating the Share Buttons by AddThis plugin or replacing it with another plugin that is compatible with WPML. You can find a list of WPML-compatible plugins here.

If this solution does not resolve your issue or seems outdated, please check for related known issues at https://wpml.org/known-issues/, verify the version of the permanent fix, and confirm that you have installed the latest versions of themes and plugins. If the problem persists, we highly recommend opening a new support ticket here.

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.

Tagged: 

This topic contains 3 replies, has 0 voices.

Last updated by Lucas Vidal de Andrade 1 week, 6 days ago.

Assisted by: Lucas Vidal de Andrade.

Author Posts
July 31, 2025 at 2:59 pm

nickK-11

Background of the issue:
I am trying to update our site to PHP 8.3 from 7.4. However, when we do this and attempt to log in, we encounter a loop on the login screen. Our hosting company and we are quite technical, and we have identified that the issue occurs when three WPML plugins are enabled. The problem does not occur on PHP 7.4. This issue is similar to a problem described here: https://wpml.org/forums/topic/fatal-error-after-php-upgrade/. We also experience this behavior on a staging site from eqs. The issue can be seen at: hidden link

Symptoms:
When attempting to log in after upgrading to PHP 8.3, I get a loop on the login screen and nothing happens. This does not occur on PHP 7.4.

Questions:
Why does enabling WPML plugins cause a login loop on PHP 8.3?
How can we resolve the login loop issue when using PHP 8.3 with WPML plugins?

July 31, 2025 at 3:16 pm
July 31, 2025 at 3:59 pm #17285707

Lucas Vidal de Andrade
WPML Supporter since 11/2023

Languages: English (English ) Spanish (Español ) German (Deutsch ) Portuguese (Brazil) (Português )

Timezone: America/Sao_Paulo (GMT-03:00)

Hello there,

I ran some tests and enabled script debugging on the local copy of your website. Here's what I found: I switched to a default theme and left only WPML Multilingual CMS and Share Buttons by AddThis activated. Both must be active for the issue to happen with PHP 8.3. If either one is deactivated, the website works again.

The issue is likely being caused by a conflict between WPML Multilingual CMS and the Share Buttons by AddThis plugin when using PHP 8.3. When both are active, WPML's script (sitepress-scripts) adds an inline JavaScript block that grows uncontrollably, repeating the same line thousands of times. This leads to the site running out of memory and crashing.

This problem does not happen with PHP 7.4, and it’s likely due to how PHP 8.3 handles memory and script processing.

The easy fix here, is to remove the AddThis plugin, or replace it with a WPML compatible one. If there is one that does the same job, you can find here:
https://wpml.org/plugin/

Let me know if this is a viable option for you.

August 1, 2025 at 9:20 am #17287585

nickK-11

Hello Lucas,

Thanks for your quick response and intervention!

I removed the AddThis plugin on the site and changed the PHP version on the server to 8.3 and everything works like intended!

Many thanks for your help!

Best regards,
Nick

August 1, 2025 at 3:54 pm #17288991

Lucas Vidal de Andrade
WPML Supporter since 11/2023

Languages: English (English ) Spanish (Español ) German (Deutsch ) Portuguese (Brazil) (Português )

Timezone: America/Sao_Paulo (GMT-03:00)

Hey there Nick,

I'm glad I was able to help. Since the issue was solved, I'll close it here. Reach out via chat, in case you have any questions in the future 🙂