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 8 replies, has 2 voices.

Last updated by J.P. 5 days, 20 hours ago.

Assigned support staff: Bobby.

Author Posts
October 2, 2019 at 3:35 pm

J.P.

I am running WPML on a Woocommerce site.

I've run into a problem in the last few days.

Here's what's been happening.

1. I add a new product in the default language English
2. I then translate that product into French
3. The French translations are accessible when I'm logged into the admin area, but as soon as I log out they are not.

You can see an example here:

hidden link
hidden link

Additionally, quite often the when I select "Translation is complete" and click save, the system seems to hang and never saves.

Please let me know if you need any additional information.

October 2, 2019 at 7:20 pm #4682857

Bobby
Supporter

Languages: English (English )

Timezone: America/Los_Angeles (GMT-07:00)

Hello,

This is happening because the product is not yet "published" rather it is set to "draft".

Notice that your translated products URL includes the product id

?post_type=product&p=2484&lang=fr

, also if you go to Products -> French Products you will see the status set to "Draft".

I did a quick test by creating a sample product and translating it; The results were as expected.

Please publish it and let me know your results.

October 2, 2019 at 7:52 pm #4683019

J.P.

Thank you for getting back to me.

This sheds some light on the problem. However, things still don't seem to be working properly.

When adding the French translations I generally click the "Translation is complete" box and hit "Save & Close"

This used to automatically save the French translation and publish it. I never had to go to Products -> French Products and publish them separately.

Additionally, as I had mentioned, the "Save & Close" function is now hanging 90% of the time that I use it. The icon seems to spin endlessly without every completing the function.

Also... when I tried to publish the French translations I get the following message.

"The recommended way to translate WooCommerce products is using the WooCommerce Multilingual products translation page. Please use this page only for translating elements that are not available in the WooCommerce Multilingual products translation table."

October 3, 2019 at 5:28 pm #4690199

Bobby
Supporter

Languages: English (English )

Timezone: America/Los_Angeles (GMT-07:00)

Hello,

1. I have created a product WPML Test 2 and then add a translation using the WPML Translation Editor and it worked as expected. It was published as soon as the translation was saved.

2. The message that you are seeing is correct as you are expected to translate the products using the Translation Editor screen by default as seen in my screenshot.

3. I did, however, reproduce the issue where the process of saving hangs and loads forever.
This is happening due to an error 500, which is usually related to running out resources in the server.

Please increase your WP MEMORY LIMIT to 256M or higher

Documentation:
https://wordpress.org/support/article/editing-wp-config-php/#increasing-memory-allocated-to-php

After increasing your WP MEMORY LIMIT let me know your results, please.

October 4, 2019 at 2:56 pm #4696743

J.P.

I'm still having problems.

I've increased the memory to 500, but it still seems to hang intermittently. I'm not sure if the memory limit issue is causing both problems.

I was able to successfully translate two test products this morning, but only after multiple attempts

hidden link
hidden link

Here's the process I've been using:

1. I created a product called "Friday Test" in English
2. Published the page. This worked fine.
3. Clicked the "Duplicate" link to create the French translation
4. The Translation Editor appeared.
5. Clicked "Copy all fields from original"
6. Selected "Translation is complete"
7. Clicked "Save and close"

One of three things then occur.

1. It saves properly and creates the French translation
2. It appears to save properly, but no translation is created
3. It hangs

I'm not sure what's going on since the site has been working properly for years. This just started in the last week or so.

October 4, 2019 at 6:48 pm #4698255

Bobby
Supporter

Languages: English (English )

Timezone: America/Los_Angeles (GMT-07:00)

Thank you for updating me!

If possible please update your PHP version from 5.6 to a higher version(PHP 7.3) as that will help with the overall performance on your site as it is hosted on a managed WP server.

Additionally, your database is over 2gb(mainly pdfs) in size therefore please do contact GoDaddy as well to increase the WP MEMORY LIMIT from their side as well.

I was able to create a package using the plugin Duplicator to test locally.

In my local environment, I am using PHP 7.3.1 and I was not able to reproduce the issue.

1 issue that did come up was a FATAL Error caused by a mismatch in the database, as I am not sure if this was caused by the migration or existing in your site please provide me with your error log as well.

You can see how to enable debug logging here:
https://wpml.org/documentation/support/debugging-wpml/

Go in your wp-config.php file and look for define(‘WP_DEBUG’, false);. Change it to:
define('WP_DEBUG', true);

Edit your wp-config.php file and add these lines, just before it says 'stop editing here':

ini_set('log_errors',TRUE);
ini_set('error_reporting', E_ALL);
ini_set('error_log', dirname(__FILE__) . '/error_log.txt');

This will create an error_log.txt file in your site's root directory. Please send me its contents.

October 7, 2019 at 1:45 pm #4707937

J.P.

Hi Bobby,

Sorry for the delay. I wasn't working over the weekend.

I've upgraded to php 7.2. (that's the highest version available with Godaddy)

I've also enabled the debug logging as requested.

Regarding the PDF files... There are a few large ones in the root directory, but I don't think any are actually loaded into the database. So I'm not sure these would affect the size/speed.

Please let me know if you need me to do anything else on this end.

Thanks,

October 7, 2019 at 9:28 pm #4710843

Bobby
Supporter

Languages: English (English )

Timezone: America/Los_Angeles (GMT-07:00)

Are you still experiencing the issue?

I did a few tests and i was not able to reproduce it now. If you are please point me to the specific one causing this behavior as I am not able to reproduce it anymore.

October 8, 2019 at 12:44 pm #4715219

J.P.

My issue is resolved now. Thank you very much!