Skip to content Skip to sidebar

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.

Sun Mon Tue Wed Thu Fri Sat
9:00 – 18:00 9:00 – 18:00 9:00 – 18:00 9:00 – 18:00 9:00 – 18:00 - -
- - - - - - -

Supporter timezone: Asia/Yerevan (GMT+04:00)

This topic contains 5 replies, has 0 voices.

Last updated by Christopher Amirian 1 month, 3 weeks ago.

Assisted by: Christopher Amirian.

Author Posts
November 16, 2025 at 3:05 am #17581226

shaneB-8

Background of the issue:
I am trying to use WPML installed network-wide, but not all subsites have configured it entirely. When editing pages on one site, I encountered a PHP error. I checked the code and found that on lines 168-169, you are doing: `$settings = apply_filters( 'wpml_setting', false, 'translation-management' ); if ( array_key_exists( 'custom_fields_convert_to_sticky', $settings ) ) {`.

But you should be doing: `$settings = apply_filters( 'wpml_setting', false, 'translation-management' ); if ( !empty($settings) && array_key_exists( 'custom_fields_convert_to_sticky', $settings ) ) {`.

This is because you need to check the response to ensure it is not `false` being returned as you provided by default, or you change the default to an empty array.

Symptoms:
Fatal error: WPML Sticky Links is causing WSOD under certain conditions. PHP Fatal error: Uncaught TypeError: array_key_exists(): Argument #2 ($array) must be of type array, bool given in /wordpress/wp-content/plugins/wpml-sticky-links/classes/custom-fields.php:170.

Questions:
Can you please fix this in core WPML Sticky Links so I no longer have to hotpatch it. Thank you for your amazing work!

November 16, 2025 at 1:58 pm #17581570

Christopher Amirian
WPML Supporter since 07/2020

Languages: English (English )

Timezone: Asia/Yerevan (GMT+04:00)

Hi,

Welcome to WPML support. Thank you for the details. Just to make sure we are on the same page, I wonder why you use the WPML Sticky Links plugin now?

That plugin is a legacy one and I do not see any use cases for a long time.

So maybe you can remove that plugin altogether?

Thanks.

November 19, 2025 at 2:20 am #17589917

shaneB-8

So does that mean that the functionality in that is being incorporated elsewhere? I'm happy to remove it from my stack I just want to fully understand why it's still offered for download if it's not really supported?

Thanks!

November 19, 2025 at 2:58 pm #17592449

Christopher Amirian
WPML Supporter since 07/2020

Languages: English (English )

Timezone: Asia/Yerevan (GMT+04:00)

Well, WordPress has come a long way when it comes to keeping track of the URLs correctly and the plugin is only for cases where the links are changed at a level suggested here:

https://wpml.org/documentation/getting-started-guide/sticky-links/

But honestly, I did not see any use cases for five years of supporting WPML.

I suggest that you deactivate WPML Sticky Link and check to see if the website works correctly.

Most probably it will with no issues.

Thanks.

November 20, 2025 at 2:37 am #17593765

shaneB-8

Fair enough. I do think that it could be fixed given it just requires a check to see if an array is returned or not pass FALSE, because it actually was causing a WSOD on several sites we have.

November 20, 2025 at 12:32 pm #17595497

Christopher Amirian
WPML Supporter since 07/2020

Languages: English (English )

Timezone: Asia/Yerevan (GMT+04:00)

Hi,

Thank you. I will consult with our dev team about this. But for now, the recommendation is to remove that plugin from the loop.

Thanks.

The topic ‘[Closed] Fatal error: WPML Sticky Links is causing WSOD under certain condition’ is closed to new replies.