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: Exception
This topic contains 22 replies, has 3 voices.
Last updated by Bobby 11 months, 1 week ago.
Assisted by: Bobby.
Author | Posts |
---|---|
May 10, 2023 at 12:32 pm #13622527 | |
Alex Seyed |
Hello, so i tried to access the woocommerce brands or categories (backend) for edit purposes and it returned a critical error page. |
May 10, 2023 at 12:58 pm #13622763 | |
Alex Seyed |
Also i confirmed that the WPML CMS plugin is the issue by deactivating it. |
May 11, 2023 at 1:13 am #13626761 | |
Bobby Supporter
Languages: English (English ) Timezone: America/Los_Angeles (GMT-07:00) |
Hello, If possible please share with me the full error from the error log. You can copy and paste it here or share it with a service such as we transfer, google drive, or dropbox. Also, verify you are using the latest version of WPML listed here |
May 11, 2023 at 8:18 am #13628001 | |
Alex Seyed |
[09-May-2023 13:23:33 UTC] PHP Warning: foreach() argument must be of type array|object, null given in sitepress-multilingual-cms/classes/notices/class-wpml-notices.php on line 480 |
May 11, 2023 at 6:21 pm #13632677 | |
Bobby Supporter
Languages: English (English ) Timezone: America/Los_Angeles (GMT-07:00) |
Hello, This warning should not cause any issue with your site. Warnings and Notices in WordPress will not cause your site's function to halt at any time therefore they do not pose a threat to the way your site or plugins are functioning. I would like to request temporary access (wp-admin and FTP) to your site to test the issue. **Before we proceed It is necessary to take FULL BACKUP of your database and your website. By providing us with access, you agree that a backup has been taken ** I often use the Duplicator plugin for this purpose: http://wordpress.org/plugins/duplicator/ NOTE: If access to the live site is not possible and the staging site does not exist please provide me with a duplicator package created with the duplicator plugin. Thank you, |
May 12, 2023 at 8:12 pm #13639261 | |
Bobby Supporter
Languages: English (English ) Timezone: America/Los_Angeles (GMT-07:00) |
Hi there, This is the full fatal error that is triggered by WooCommerce but it does resolve with WPML disabled indeed. Do I have your permission to migrate the site to our Cloudways staging environment? It is private, secure and it will allow us to test without the risk of testing on a live site. [12-May-2023 19:47:45 UTC] PHP Fatal error: Uncaught TypeError: array_search(): Argument #2 ($haystack) must be of type array, null given in /home/ministry/public_html/wp-content/plugins/woocommerce/src/Admin/API/Reports/PerformanceIndicators/Controller.php:540 Stack trace: #0 /home/ministry/public_html/wp-content/plugins/woocommerce/src/Admin/API/Reports/PerformanceIndicators/Controller.php(540): array_search() #1 /home/ministry/public_html/wp-includes/class-wp-hook.php(308): Automattic\WooCommerce\Admin\API\Reports\PerformanceIndicators\Controller->format_data_value() #2 /home/ministry/public_html/wp-includes/plugin.php(205): WP_Hook->apply_filters() #3 /home/ministry/public_html/wp-content/plugins/woocommerce/src/Admin/API/Reports/PerformanceIndicators/Controller.php(437): apply_filters() #4 /home/ministry/public_html/wp-includes/rest-api/class-wp-rest-server.php(1181): Automattic\WooCommerce\Admin\API\Reports\PerformanceIndicators\Controller->get_items() #5 /home/ministry/public_html/wp-includes/rest-api/class-wp-rest-server.php(1028): WP_REST_Server->respond_to_request() #6 /home/ministry/public_html/wp-includes/rest-api/class-wp-rest-server.php(442): WP_REST_Server->dispatch() #7 /home/ministry/public_html/wp-includes/rest-api.php(410): WP_REST_Server->serve_request() #8 /home/ministry/public_html/wp-includes/class-wp-hook.php(308): rest_api_loaded() #9 /home/ministry/public_html/wp-includes/class-wp-hook.php(332): WP_Hook->apply_filters() #10 /home/ministry/public_html/wp-includes/plugin.php(565): WP_Hook->do_action() #11 /home/ministry/public_html/wp-includes/class-wp.php(399): do_action_ref_array() #12 /home/ministry/public_html/wp-includes/class-wp.php(780): WP->parse_request() #13 /home/ministry/public_html/wp-includes/functions.php(1334): WP->main() #14 /home/ministry/public_html/wp-blog-header.php(16): wp() #15 /home/ministry/public_html/index.php(17): require('/home/ministry/...') #16 {main} thrown in /home/ministry/public_html/wp-content/plugins/woocommerce/src/Admin/API/Reports/PerformanceIndicators/Controller.php on line 540 |
May 15, 2023 at 9:41 am #13646585 | |
Alex Seyed |
Hi Bobby, yes go on. |
May 16, 2023 at 4:36 pm #13658205 | |
Bobby Supporter
Languages: English (English ) Timezone: America/Los_Angeles (GMT-07:00) |
Hi Alex, I have attempted to do the migration but it's failing due to the size of an old error log. If possible, try the following: go to wp-content/debug_2.log and delete it -> currently it's 16GB Additionally, I did try to migrate using a duplicator package but this is not working as expected at the moment. Please let me know once the file has been removed and I will proceed again |
May 17, 2023 at 12:10 pm #13664013 | |
Alex Seyed |
File removed! |
May 18, 2023 at 12:42 am #13668527 | |
Bobby Supporter
Languages: English (English ) Timezone: America/Los_Angeles (GMT-07:00) |
Thank you, I was able to create a duplicator package to test locally. In the local environment, I am able to access the brand's area without getting an error. The only difference between the local environment and your site is that Wordfence is disabled. - Please try with Wordfence deactivated and let me know your results. - Do you currently have a way of testing on a local or staging environment? |
May 18, 2023 at 9:11 am #13670315 | |
Alex Seyed |
I deactivated Wordfence and the issue persists. |
May 18, 2023 at 11:57 pm #13675419 | |
Bobby Supporter
Languages: English (English ) Timezone: America/Los_Angeles (GMT-07:00) |
If that is possible that would be great at the moment I have only been able to test on a local environment where I cannot reproduce this issue to further work on it. |
May 19, 2023 at 12:01 pm #13679037 | |
Alex Seyed |
Hello Bobby, I created a staged website. Thanks. |
May 19, 2023 at 9:47 pm #13681543 | |
Bobby Supporter
Languages: English (English ) Timezone: America/Los_Angeles (GMT-07:00) |
Thank you, I was able to remove the fatal error by going to WPML->Settings->Taxonomies Translation and setting Brands to "Not Translatable". How were Brands created? I have created a clean sandbox for us with just XSTORE and WPML but do not see the brand taxonomy. see here: hidden link Please access it and re create the taxonomy there |
May 22, 2023 at 9:05 am #13687503 | |
Alex Seyed |
The brands taxonomy is a function of the theme itself. |