Skip Navigation

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

Problem:
The client experiences a 404 error when trying to open English pages on their multilingual website, although the pages exist in both Turkish and English. The error does not occur when switching from Turkish to English on the same page.

Solution:

After further investigation during a chat with the client, it was observed that there was a lot of custom code added in functions.php file which was causing this irregular behavior. Pages were throwing 404 randomly.

Since custom coding is out of scope of this forum, we advised the client to remove all the code and check piece by piece while keeping an eye on the issue.

If this solution does not resolve the issue or seems irrelevant due to being outdated or not applicable to your case, we highly recommend checking related known issues at https://wpml.org/known-issues/, verifying the version of the permanent fix, and confirming that you have installed the latest versions of themes and plugins. If the problem persists, please open a new support ticket for further assistance.

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

Last updated by Waqas Bin Hasan 2 weeks ago.

Assisted by: Waqas Bin Hasan.

Author Posts
January 27, 2025 at 10:25 am

keremO-2

Background of the issue:
I am trying to open pages in English from my website. When I'm at the home page, I click the English button, and it opens without a problem. However, when I click another page, it sometimes gives a 404 error. The page works in both Turkish and English versions. If I go to that page in Turkish mode, it opens, and then I click the English button, it opens again. The issue can be seen at: hidden link

Symptoms:
I sometimes get a 404 error when trying to open English pages from my website.

Questions:
Why do I get a 404 error when trying to open English pages?
How can I ensure the English pages open without errors?

January 27, 2025 at 11:24 am
January 27, 2025 at 11:26 am #16637373

Waqas Bin Hasan
Supporter

Languages: English (English )

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

Hi,

Reference to our recent chat, please let me know when staging/test site is ready.

Your next answer will be private, to share this information safely.

Also provide detailed steps to reproduce the issue and links to pages in the admin and on the frontend.

IMPORTANT: Please take a complete backup of the site to avoid data loss. I may need to activate/deactivate plugins also.

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

P.S.: If you don't see the section for providing access information, do not write in the message box or the information may appear as public.

Regards.