Skip to content Skip to sidebar

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

Problem:
You are experiencing issues with the WPML CMS Nav plugin on your website after updating to PHP 8.2. The specific problem involves deprecated property creation warnings in the plugin's code, which could affect compatibility with PHP 8.2 and future versions.
Solution:
We are planning to address this issue in future updates of the WPML CMS Nav plugin. Although these warnings are harmless to your site, you can continue using the workaround previously suggested.

Please note that this solution might be irrelevant if it's outdated or not applicable to your case. We highly recommend checking related known issues at https://wpml.org/known-issues/, verifying the version of the permanent fix, and confirming that you have installed the latest versions of themes and plugins. If the issue persists, please open a new support ticket at WPML support forum.

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 1 voice.

Last updated by Andrey 2 days ago.

Assisted by: Andrey.

Author Posts
August 1, 2024 at 12:57 am #16027237

madH

Background of the issue:
I am experiencing an issue with the WPML CMS Nav plugin on my website. Since updating to PHP 8.2, I have encountered deprecated property creation warnings in the plugin's code.

Symptoms:
The specific warnings are as follows:
[01-Aug-2024 00:34:34 UTC] PHP Deprecated: Creation of dynamic property wpml_cms_nav_cache::$name is deprecated in /home/www/madhouse.rs/wp-content/plugins/wpml-cms-nav/inc/cache.class.php on line 36
[01-Aug-2024 00:34:34 UTC] PHP Deprecated: Creation of dynamic property wpml_cms_nav_cache::$cache_to_option is deprecated in /home/www/madhouse.rs/wp-content/plugins/wpml-cms-nav/inc/cache.class.php on line 37

These warnings indicate that the creation of dynamic properties in the wpml_cms_nav_cache class is deprecated and should be addressed to ensure compatibility with PHP 8.2 and future versions.

Questions:
Could you please provide an update or patch to resolve this issue? I would greatly appreciate any assistance you can offer to help fix this problem without having to modify the plugin's code directly.

Thank you for your prompt attention to this matter.

Best regards,

Sanja

August 1, 2024 at 3:49 pm #16030595

Bigul

Hi Sanja,

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

We can reproduce this error here and it has been forwarded to our team. This will be fixed in the future version of WPML CMS Nav.

This alert won't affect the normal functioning of your site. As a temporary workaround, we recommend setting debug mode to false by adding or changing the following code in your wp-config.php file, located at the root of your WordPress installation:

define('WP_DEBUG', false);

This should help to resolve the issue until a permanent solution is implemented in future releases. Please try it after a site backup and let us know your feedback.

--
Thanks!

Bigul

April 2, 2025 at 1:35 pm #16887371

ikkiL

Hello,
To hide this error add :
#[\AllowDynamicProperties]

just before :
class wpml_cms_nav_cache{

in : wp-content\plugins\wpml-cms-nav\inc\cache.class.php

September 18, 2025 at 3:41 pm #17414181

Andrey
WPML Supporter since 06/2013

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

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

Just a follow-up on this issue: it will be addressed in future updates of the WPML CMS Nav plugin. The warnings are harmless to your site. You can continue using the workaround suggested earlier.

If you're not utilizing the features of the WPML CMS Nav plugin, you might consider deactivating it.