Skip Navigation

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

Problem:
The client was trying to hide a language and save the settings, but encountered a blank page. Additionally, when attempting to add/remove a language, the page got stuck on 'Downloading translations... Please don't close this page.'.
Solution:
We recommended the client to first deactivate all plugins except WPML to check if the issue persists. If the blank page still appears, it indicates a PHP error. To diagnose this, we advised enabling debugging in the WordPress configuration. This involves editing the

wp-config.php

file to set

define('WP_DEBUG', true);

and

define('WP_DEBUG_LOG', true);

, which logs errors to a

debug.log

file in the

/wp-content/

directory. For detailed steps, visit WPML Debugging Documentation.
After enabling debugging, if errors are identified, we suggested deactivating all plugins and reactivating them one by one to pinpoint the problematic plugin. We also advised backing up the database before making these changes.

If this solution does not resolve the issue or seems outdated, please check 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 problems persist, we highly recommend opening a new support ticket for further assistance.

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.

Our next available supporter will start replying to tickets in about 7.96 hours from now. Thank you for your understanding.

Tagged: 

This topic contains 5 replies, has 2 voices.

Last updated by Andrey 1 week, 4 days ago.

Assisted by: Andrey.

Author Posts
May 4, 2024 at 12:21 am #15592978

davidL-161

Tell us what you are trying to do?
I was trying to hide a language SC and then press SAVE but the page just becomes blank. Then I tried to Add/Remove Language and unchecked SC and press SAVE, but the page stays at Downloading translations... Please don't close this page forever.

Is there any documentation that you are following?

Is there a similar example that we can see?

What is the link to your site?
hidden link

May 4, 2024 at 7:18 am #15593153

Andrey
Supporter

Languages: English (English ) Russian (Русский )

Timezone: Europe/Kyiv (GMT+03:00)

Thank you for contacting WPML support.

Does the same issue happen if you temporarily deactivate all plugins except WPML?

If you are still experiencing the blank page, it means that there is an error in the PHP code that your site runs. When errors are not caught, the server stops everything and returns a page that says “500 error” or an empty page. Different servers are configured to display these errors slightly differently, but they all mean the same – there is an unhandled PHP error in the site’s code.

First, you need to see what the errors are. The first step is to enable debugging. You can do this by adding a few lines to the site’s wp-config.php file. With error log enabled, you will see what the actual problem is.

To enable it, open your wp-config.php file and look for define(‘WP_DEBUG’, false);. Change it to:

define('WP_DEBUG', true);

In order to enable the error logging to a file on the server you need to add yet one more similar line:

define( 'WP_DEBUG_LOG', true );

In this case, the errors will be saved to a debug.log log file inside the /wp-content/directory.

https://wpml.org/documentation/support/debugging-wpml/

Let me know what you see in the debug.log after the debug mode has been enabled.

May 7, 2024 at 12:41 am #15599513

davidL-161

Hi Andrey

Here is the error displayed when I try to hide the SC language

Deprecated: strpos(): Passing null to parameter #1 ($haystack) of type string is deprecated in /storage-raid/www/xxx/wp-includes/functions.php on line 7288

Deprecated: str_replace(): Passing null to parameter #3 ($subject) of type array|string is deprecated in /storage-raid/www/xxx/wp-includes/functions.php on line 2187

Deprecated: Constant FILTER_SANITIZE_STRING is deprecated in /storage-raid/www/xxx/wp-content/plugins/imagify-tools/classes/class-imgt-admin-pages.php on line 132

If I just load the Language Setting page in WPML, it shows these above the page
Deprecated: strpos(): Passing null to parameter #1 ($haystack) of type string is deprecated in /storage-raid/www/xxx/wp-includes/functions.php on line 7288

Deprecated: str_replace(): Passing null to parameter #3 ($subject) of type array|string is deprecated in /storage-raid/www/xxx/wp-includes/functions.php on line 2187

Deprecated: Constant FILTER_SANITIZE_STRING is deprecated in /storage-raid/www/xxx/wp-content/plugins/imagify-tools/classes/class-imgt-admin-pages.php on line 132

Deprecated: rtrim(): Passing null to parameter #1 ($string) of type string is deprecated in /storage-raid/www/xxx/wp-includes/formatting.php on line 2831

Deprecated: rtrim(): Passing null to parameter #1 ($string) of type string is deprecated in /storage-raid/www/xxx/wp-includes/formatting.php on line 2831

Deprecated: rtrim(): Passing null to parameter #1 ($string) of type string is deprecated in /storage-raid/www/xxx/wp-includes/formatting.php on line 2831

Deprecated: rtrim(): Passing null to parameter #1 ($string) of type string is deprecated in /storage-raid/www/xxx/wp-includes/formatting.php on line 2831

May 7, 2024 at 12:37 pm #15601934

Andrey
Supporter

Languages: English (English ) Russian (Русский )

Timezone: Europe/Kyiv (GMT+03:00)

Thank you for your feedback. Those are warnings; those should be harmless, and I see no WPML-related ones. Do you see any fatal errors in the debug.log? What are the results with non-WPML plugins deactivated?

May 7, 2024 at 6:15 pm #15603515

davidL-161

No log entries in debug.log

But I did try to disable all plugins and was able to hide the language.

May 7, 2024 at 7:36 pm #15603828

Andrey
Supporter

Languages: English (English ) Russian (Русский )

Timezone: Europe/Kyiv (GMT+03:00)

It seems that one of the plugins is causing the issue. I recommend deactivating all plugins and then activating them one by one to determine which one is causing the problem.

Please backup your database before making any changes.

This ticket is now closed. If you're a WPML client and need related help, please open a new support ticket.