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.

This topic contains 5 replies, has 2 voices.

Last updated by Bigul 9 months, 2 weeks ago.

Assigned support staff: Bigul.

Author Posts
January 4, 2019 at 4:43 pm #3057289

maxieM

I am trying to:

Delete products in a disabled language (Spanish), but they do not appear under 'Products'.

WPML > Languages reports reports 75 Spanish products and other Spanish content, although we deleted all Spanish products, before disabling the language. The spanish products appear in strange places even when the language is disabled, but not under 'Products', when it is enabled. They for instance appear under 'Related products' and can be selected as 'Product' or 'Excluded products' on a coupon. They also create SKU conflicts with other products, which means we can't use the correct SKUs in some cases.

I expected to see:

Spanish products.

Instead, I got:

Zero Spanish products.

Note that our theme is quite outdated (no longer updated) and we'll change soon, but I don't see how that could have anything to do with this case, since this is an issue with the backend, not the frontend.

January 4, 2019 at 6:24 pm #3057549

Bigul
Supporter

Languages: English (English )

Timezone: Asia/Kolkata (GMT+05:30)

Hello,

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

Please try the following troubleshooting steps after a site backup and make sure the issue is existing or not.

1) Go to WPML>>Support page
2) Click on Troubleshooting link (blue link in the middle of the page)
3) In Troubleshooting page, please click on the following options of the *Clean up* section. Wait for confirmation of processing after each one.

- Clear the cache in WPML
- Remove ghost entries from the translation tables
- Fix element_type collation
- Set language information
- Assign translation status to duplicated content
- Fix terms count
- Fix post type assignment

--
Thanks!

Bigul

January 7, 2019 at 5:13 pm #3063893

maxieM

Hello Bigul,

Thanks for your response.

I deleted cache and followed your instructions. However, "Set language information" kept running, so I opened the console which revealed a 500 server error.

Apache's error.log shows:

[Mon Jan 07 17:46:35.641319 2019] [proxy_fcgi:error] [pid 29562:tid 140695561766656] [client 85.246.154.178:49735] AH01071: Got error 'PHP message: PHP Fatal error:  Uncaught InvalidArgumentException: element_id and type do not match for element_id:16968 the database contains post_product_variation while this function was called with post_product in /var/www/shop/web/wp-content/plugins/sitepress-multilingual-cms/classes/core-abstract-classes/class-wpml-set-language.php:32\nStack trace:\n#0 /var/www/shop/web/wp-content/plugins/sitepres
s-multilingual-cms/sitepress.class.php(1433): WPML_Set_Language->set('16968', 'post_product', NULL, 'en', NULL, true)\n#1 /var/www/shop/web/wp-content/plugins/sitepress-multilingual-cms/inc/translation-management/translation-management.class.php(1860): SitePress->set_el
ement_language_details('16968', 'post_product', NULL, 'en')\n#2 /var/www/shop/web/wp-content/plugins/sitepress-multilingual-cms/inc/translation-management/translation-management.class.php(1830): TranslationManagement->add_missing_language_to_post(Object(stdClass))\n#3 /
var/www/shop/web/wp-content/plugins/sitepress-multilingual-cms/inc/translation-m...\n', referer: <em><u>hidden link</u></em>

Does this ring a bell?

January 8, 2019 at 9:24 am #3065963

Bigul
Supporter

Languages: English (English )

Timezone: Asia/Kolkata (GMT+05:30)

Hello,

Thank you for the updates. This kind of error is happening because of corrupt entry or misconfiguration in the Database. In this case element_type which has element_id 16968 of wp_icl_translations database table doesn't match post_product_variation of this entry in wp_posts database table.

Please try the following steps after a full site backup to fix the issue.

1) Go to your database using phpMyAdmin(or something similar)

2) Go to wp_icl_translations database table(Maybe table prefix will be different in your case)

3) Find entry with element_id:16968 and delete that row

--
Thanks!

Bigul

January 9, 2019 at 10:04 pm #3073844

maxieM

Hi Bigul,

I followed your instructions. Deleting that single row didn't suffice. The same PHP fatal error kept occurring, each time revealing a new similar database row.

I went through the entire process (your steps) after deleting each row, only to be alerted by another one through a fatal error. Exact same error every time.

30-40'ish rows later and no end in sight, I checked the shop and discovered that product variants had turned into full fledged products, so we went from having 12 products to having hundreds of products.

Any other "good" ideas? 😉 I am leaning towards a clean WordPress install and finally getting completely rid of WPML (that will be a cause for celebration!). Your support is excellent, but man, WPML is the worst piece of you-know-what I have ever dealt with. So much time lost because of it, it's insane! Not to mention revenue...

Cheers, Lasse

January 10, 2019 at 12:53 pm #3076092

Bigul
Supporter

Languages: English (English )

Timezone: Asia/Kolkata (GMT+05:30)

Hello,

Thank you for the details. Please fill the private details fields after a full site backup. I would like to access the admin area of your site for further checking. Please check the following links for more details about our private information sharing policies.

hidden link

https://wpml.org/purchase/support-policy/privacy-and-security-when-providing-debug-information-for-support/

--
Thanks!

Bigul

The topic ‘[Closed] Ghost products in disabled language not appearing under 'Products'’ is closed to new replies.