This thread is resolved. Here is a description of the problem and solution.
Problem:
The client was experiencing an issue where clicking on the home URL in the Spanish language version of their site was redirecting to an incorrect, irrelevant page.
Solution:
First, we verified that the homepage URL for the Spanish language should not include the default language slug "es". We then suggested the client to check for possible redirections caused by other plugins or custom code. To diagnose the issue, we recommended:
1. Deactivating all non-WPML plugins.
2. Switching to a standard WordPress theme.
It is important to back up the database and website before making these changes.
After further investigation on a local copy of the client's site, we determined that the issue was not related to WPML but rather a WordPress redirection issue. We provided a code snippet to add to the
functions.php
file in the theme folder to fix the issue:
remove_action('template_redirect', 'redirect_canonical');
We advised the client to apply this code to their site and to ensure a backup is made before proceeding.
Please note that this solution might be irrelevant if it's outdated or not applicable to your case. If you're still experiencing issues, we highly recommend checking related 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 with us.
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 is split from https://wpml.org/forums/topic/popup-builder-2/
This topic contains 5 replies, has 2 voices.
Last updated by 7 months, 2 weeks ago.
Assisted by: Long Nguyen.