This thread is resolved. Here is a description of the problem and solution.
Problem:
The client was experiencing an issue where clicking the Slovak flag on their website redirected to an incorrect URL instead of switching back to the Slovak version of the site.
Solution:
We recommended the following steps to diagnose and potentially resolve the issue:
1. Clear Cache: We advised clearing WPML’s internal cache from WPML > Support > Troubleshooting > Clear the cache in WPML, disabling the Language Switcher Cache, clearing any site caching plugins, and the CDN cache if applicable.
2. Use Footer Language Switcher: We suggested activating a footer language switcher from WPML > Languages to check if the issue persists with a different switcher setup.
3. Test in Minimal Environment: We recommended deactivating all plugins except WPML CMS and switching temporarily to a default WordPress theme like Twenty Twenty-one to see if the issue still occurs. This helps in identifying any conflicts with other plugins or themes.
Ultimately, the client discovered that the issue was caused by incorrect custom codes provided by their hosting service for redirecting www/non-www URLs in the wp-config file. Removing these codes resolved the problem.
If this solution does not apply to your case, or if it seems outdated, 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 issues persist, please open a new support ticket.
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.