Skip Navigation

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.

Sun Mon Tue Wed Thu Fri Sat
- 9:00 – 18:00 9:00 – 18:00 9:00 – 18:00 9:00 – 18:00 9:00 – 18:00 -
- - - - - - -

Supporter timezone: Asia/Karachi (GMT+05:00)

This topic contains 3 replies, has 3 voices.

Last updated by Waqas Bin Hasan 10 months, 2 weeks ago.

Assisted by: Waqas Bin Hasan.

Author Posts
March 6, 2024 at 4:28 pm #15380788

rodrigoO-4

Tell us what you are trying to do?
When accessing some products in a language other than PT, a 404 error occurs

Is there any documentation that you are following?

Is there a similar example that we can see?

What is the link to your site?
hidden link

scrnli_06_03_2024_16-27-51.png
March 6, 2024 at 7:35 pm #15381354

Mateus Getulio
Supporter

Languages: English (English ) Portuguese (Brazil) (Português )

Timezone: America/Sao_Paulo (GMT-03:00)

Hi,

Thanks for contacting us.

Before your ticket is assigned to one of my colleagues, please allow me to walk you through some initial debugging steps. This will help speed up the support process.

I checked it and it does seem to be happening to the products that belong to the women-no-pressure-cuff category:

hidden link

As a test, can you please go to String Translation, check the option 'include translation' and search for the 'women no pressure cuff' category? Then you select the string and delete it(it's going to delete it for all languages).

After that, please go to WPML -> WooCommerce Multilingual -> Categories and re-translate this category for all languages, and check if the issue persists.

If so, I'd like your help enabling the debug mode to help us track the error down, please add the following code to the wp-config.php file:

// Enable WP_DEBUG mode
define( 'WP_DEBUG', true );
  
// Enable Debug logging to the /wp-content/debug.log file
define( 'WP_DEBUG_LOG', true );
  
// Disable display of errors and warnings 
define( 'WP_DEBUG_DISPLAY', false );
@ini_set( 'display_errors', 0 );
  
// Use dev versions of core JS and CSS files (only needed if you are modifying these core files)
define( 'SCRIPT_DEBUG', true );

Please check following links to read more about debugging with WordPress.
- https://codex.wordpress.org/Debugging_in_WordPress
- https://codex.wordpress.org/Debugging_in_WordPress#Example_wp-config.php_for_Debugging

After adding the code above, please try to reproduce the issue again and check if you'll find a debug.log file inside the wp-content folder.

If you locate it there, please send us the last lines here in the ticket.

After you send the WP debug logs, we'll analyze them and get back to you with further steps.

Looking forward to helping you resolve this issue.

March 6, 2024 at 9:28 pm #15381692

rodrigoO-4

Hello.

When searching in string translation, no content appears.

scrnli_06_03_2024_21-28-32.png
March 7, 2024 at 9:31 am #15382982

Waqas Bin Hasan
Supporter

Languages: English (English )

Timezone: Asia/Karachi (GMT+05:00)

Hi,

Thank you for contacting the support. I am assigned this ticket and 'll try my best to help you solve the problem.

I see that 404 is only happening for English translation of hidden link, while French and German seem to work fine.

One thing I noticed that PT and EN have same slug for the product (other than /en/ and product category parts in the URL). Can you try changing the English slug for the product and check again?

If this doesn't help, can you please try the following?

IMPORTANT: Take full backup of your website and database beforehand. It is highly advised to try the following on a staging/dev site first, so your live website isn't compromised.

- Fix “WP Memory Limit” to at least 128MB while 256MB is recommended. See https://wpml.org/home/minimum-requirements/ for detailed information. You can set this in your wp-config.php file by adding following code:

define( 'WP_MEMORY_LIMIT', '128M' );
define( 'WP_MAX_MEMORY_LIMIT', '256M' );

Remember to add these lines before the line where it says:
/* That's all, stop editing! Happy publishing. */

Then:
- Deactivate all plugins except WPML and WooCommerce and check for the issue.
- Activate each plugin one-by-one, while keeping check on the issue after a plugin is activated. This way you'll be able to pinpoint a plugin having a conflict (or problem), if any.
- If the problem persists, repeat the above steps with a default theme of WordPress (i.e. 2021 or 2024).

Please let me know and I'll try my best to help you further on the matter.

Regards.

The topic ‘[Closed] 404 error in products’ is closed to new replies.