Skip Navigation

This thread is resolved. Here is a description of the problem and solution.

Problem:
The client reported that their website was experiencing 404 errors on all pages except the homepage. They discovered a rewrite base had been set to their domain with an additional language path, which they had not configured themselves, and wondered if WPML could have caused this change.
Solution:
We informed the client that WPML does not cause such issues. Instead, it is likely due to third-party plugins that call the flush_rewrite_rules(true) function too frequently, leading to the .htaccess file being overwritten. We recommended the client to:
1. Follow the instructions in our documentation to prevent .htaccess from being overwritten: https://wpml.org/faq/why-is-htaccess-getting-overwritten-with-the-language-folder-on-my-wpml-website/
2. Re-save the permalinks and check if the issue persists.

If the provided solution does not apply or is outdated, or if the issue persists, we encourage the client to open a new support ticket. We highly recommend checking related known issues at https://wpml.org/known-issues/, verifying the version of the permanent fix, and confirming that the latest versions of themes and plugins are installed. For further assistance, please contact us in the 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: 

This topic contains 1 reply, has 2 voices.

Last updated by Marsel Nikolli 1 year, 1 month ago.

Assisted by: Marsel Nikolli.

Author Posts
March 25, 2024 at 8:07 am #15445014

mercedesA-2

Tell us what you are trying to do?
Good morning,
I had an issue that suddenly all my website went down getting errors 404 in all pages but the home.
After investigating the root cause I did realized that there was a rewritebase to cefegen.es/fr
See the images uploaded.
I did not do that.
How is possible that this was changed by wpml?

Thanks

Is there any documentation that you are following?

Is there a similar example that we can see?

What is the link to your site?

WhatsApp Image 2024-03-21 at 22.44.22.jpeg
March 25, 2024 at 8:29 am #15445068

Marsel Nikolli

Hi,

Thank you for contacting WPML Support, I will gladly help you.

This issue is not caused by WPML, it comes from certain third-party plugins calling the flush_rewrite_rules(true) function too often. This causes WordPress to overwrite .htaccess.

I would suggest you try following the instructions shown in the link here:
https://wpml.org/faq/why-is-htaccess-getting-overwritten-with-the-language-folder-on-my-wpml-website/

After that try re-saving the permalinks and see if the issue still happens.

* Note: Please make sure you have a full backup of your website before making any updates/changes to your website.

Let me know how it goes.

Kind regards,
Marsel