This thread is resolved. Here is a description of the problem and solution.
Problem:
When trying to 'Add new page' in Elementor with only the WPML Multilingual CMS plugin active, the page does not load and displays a grey spinning page. A JavaScript error appears in the console indicating an 'Uncaught TypeError: Cannot convert undefined or null to object'.
Solution:
We recommend adding the following code to your theme's functions.php file to address this issue:
//compsupp_7780 workaround add_action( 'elementor/document/after_save', 'compsupp_7780_after_document_save' ); function compsupp_7780_after_document_save( $document ) { $wpml_page_id = $document->get_post()->ID; wp_update_post(array('ID' => $wpml_page_id));= return $document; }
If this solution does not resolve your issue, or if it seems outdated or irrelevant 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. Additionally, you can open a new support ticket for further assistance 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: Compatibility
This topic contains 1 reply, has 1 voice.
Last updated by Shekhar Bhandari 1 month, 3 weeks ago.
Assisted by: Shekhar Bhandari.
Author | Posts |
---|---|
December 23, 2024 at 3:13 pm #16540810 | |
jamesO-17 |
Background of the issue: Symptoms: Uncaught TypeError: Cannot convert undefined or null to object at Function.entries () at loopBuilderModule.createDocumentSaveHandles (editor.min.js?ver=3.26.2:2:68348) at loopBuilderModule.onElementorFrontendInit (editor.min.js?ver=3.26.2:2:67586) at p (load-scripts.php?c=1&load%5Bchunk_0%5D=underscore,jquery-core,jquery-migrate,backbone,jquery-ui-core,jquery-ui-mouse,wp-api-request,wp-hooks&ver=6.7:10:3644) at f (load-scripts.php?c=1&load%5Bchunk_0%5D=underscore,jquery-core,jquery-migrate,backbone,jquery-ui-core,jquery-ui-mouse,wp-api-request,wp-hooks&ver=6.7:10:3497) at a (load-scripts.php?c=1&load%5Bchunk_0%5D=underscore,jquery-core,jquery-migrate,backbone,jquery-ui-core,jquery-ui-mouse,wp-api-request,wp-hooks&ver=6.7:10:692) at e.trigger (load-scripts.php?c=1&load%5Bchunk_0%5D=underscore,jquery-core,jquery-migrate,backbone,jquery-ui-core,jquery-ui-mouse,wp-api-request,wp-hooks&ver=6.7:10:3380) at Editor.initFrontend (editor.min.js?ver=3.26.3:3:547605) at Editor.onPreviewLoaded (editor.min.js?ver=3.26.3:3:559900) at editor.min.js?ver=3.26.3:3:1223080 in the console log. Questions: |
December 23, 2024 at 3:40 pm #16540912 | |
jamesO-17 |
Ive tried this https://wpml.org/forums/topic/fatal-error-uncaught-error-class-elementorcoreschemescolor/ which worked temporally but the error is occurring again now |
December 24, 2024 at 4:35 am #16542324 | |
Shekhar Bhandari Supporter
Languages: English (English ) Timezone: Asia/Kathmandu (GMT+05:45) |
Hello there, Thank you for contacting WPML support. I'd be happy to assist you on this issue. To debug this issue further, I would need to check your site settings once, for this I would need temporary access (wp-admin and ftp) to your site. So could you please provide me with those details, you will find the needed fields for this below the comment area when you log in to leave your next reply. This info is private and available to you and WPML supporters only. Note: Look forward to your reply. Thanks |
December 25, 2024 at 5:12 am #16544894 | |
Shekhar Bhandari Supporter
Languages: English (English ) Timezone: Asia/Kathmandu (GMT+05:45) |
Hello there, I enabled the WPML Plugin and I can edit this page hidden link without any issues, can you check if the problem still exists. Look forward to your reply. Thanks |
December 31, 2024 at 9:25 am #16555252 | |
jamesO-17 |
Hey, the issue occurs when you click this from that page hidden link. Did you try that? |
December 31, 2024 at 10:18 am #16555355 | |
Shekhar Bhandari Supporter
Languages: English (English ) Timezone: Asia/Kathmandu (GMT+05:45) |
Hello, I replicated your site on my localhost and couldn’t reproduce the issue—it opens without any problems on my end. The key difference is that I didn’t use the mu-plugins from WP Engine. I suspect the issue might be related to caching. Could you please disable all caching, clear the existing cache, and check if the problem persists? Also, do you have used any settings for role management in wpengine? Looking forward to your response. Thank you |
December 31, 2024 at 10:49 am #16555439 | |
jamesO-17 |
I've cleared all cache and it still doesn't work, the only thing that works for me is if I disable the WPML CMS plugin on staging and my local. |
December 31, 2024 at 11:15 am #16555512 | |
Shekhar Bhandari Supporter
Languages: English (English ) Timezone: Asia/Kathmandu (GMT+05:45) |
Hello there, Also, do you have used any settings for role management in wpengine? Also, can you ask for server logs from wpengine? Look forward to your reply. Thanks |
December 31, 2024 at 11:38 am #16555660 | |
jamesO-17 |
Hi, can you elaborate on this please? Also, do you have used any settings for role management in wpengine? And how can I upload CSV file for logs? |
January 1, 2025 at 6:06 am #16556562 | |
Shekhar Bhandari Supporter
Languages: English (English ) Timezone: Asia/Kathmandu (GMT+05:45) |
Hello there, I haven't used any settings as such, but since on my localhost, if I disable mu-plugins it works so I wanted to make sure there is not an conflict with some server settings. You can upload the csv file on google drive and share the links with me. Look forward to your reply. Thanks |
January 2, 2025 at 3:12 pm #16559312 | |
jamesO-17 |
Hey, you can find the logs here hidden link Today we have deployed the wordpress and plugin upgrades on our production website and server and we can still getting the issue now on our live and staging environments. Deactivating the WPML Multilingual CMS plugin fixes the issue. |
January 3, 2025 at 8:33 am #16560439 | |
Shekhar Bhandari Supporter
Languages: English (English ) Timezone: Asia/Kathmandu (GMT+05:45) |
Hello there, Just to let you know I am able to reproduce the error and I have escalated this to our compatibility team, I will update you as soon as I will receive any further feedback from them. Thanks |
January 3, 2025 at 12:12 pm #16561299 | |
jamesO-17 |
Thank you for your reply |
January 6, 2025 at 4:33 am #16565046 | |
Shekhar Bhandari Supporter
Languages: English (English ) Timezone: Asia/Kathmandu (GMT+05:45) |
Sure, I will update you as soon as I will receive any further feedback. Thanks |
January 10, 2025 at 3:36 pm #16582599 | |
Shekhar Bhandari Supporter
Languages: English (English ) Timezone: Asia/Kathmandu (GMT+05:45) |
Hello there, Our compatibility team checked the issue and suggested the following workaround, can you please add the following in your theme functions.php and see if it helps. //compsupp_7780 workaround add_action( 'elementor/document/after_save', 'compsupp_7780_after_document_save' ); function compsupp_7780_after_document_save( $document ) { $wpml_page_id = $document->get_post()->ID; wp_update_post(array('ID' => $wpml_page_id)); return $document; } Look forward to your reply. Thanks |