This thread is resolved. Here is a description of the problem and solution.
Problem:
After moving the site from staging to live, the WPML Menu Synchronization still shows old staging site domain names in custom links, despite them being correct in the menu itself.
Solution:
1. We identified that the issue arises because WPML does not automatically update absolute links/custom URLs in the String Translation. These are loaded from .mo files located in wp-content/languages/wpml.
2. Since .mo files are compiled and cannot be edited directly, we recommend checking the corresponding .po files that might contain the outdated URLs.
3. Alternatively, you can try the following steps:
- Navigate to WPML > Support > Troubleshooting.
- Use the option to clean up the Strings table and regenerate the .mo files. This might help update your .mo files to reflect the current strings.
4. If the issue persists, we may need a full copy of your site or at least staging access to further diagnose the problem.
Please note that this solution might be outdated or not applicable to your specific 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 continues, please open a new support ticket with us 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.
Tagged: Exception
This topic contains 10 replies, has 2 voices.
Last updated by frankG-4 1 month, 1 week ago.
Assisted by: Ilyes.
Author | Posts |
---|---|
October 22, 2024 at 9:08 am #16315929 | |
frankG-4 |
Background of the issue: Symptoms: Questions: |
October 22, 2024 at 3:57 pm #16318392 | |
Ilyes Supporter
Languages: English (English ) French (Français ) Timezone: Pacific/Easter (GMT-05:00) |
Hi, Thanks for contacting us. Are these menu items URLs set manually? I mean did you copy and paste the URLs of each page when creating the initial menu? Please allow me to walk you through some initial debugging steps. This will help speed up the support process. Can you please backup of your site and go to WPML > Support > troubleshooting and try all the following buttons: hidden link You can refer to this documentation on how to do it : https://wpml.org/documentation/support/wpml-troubleshooting-options/ Then go to Settings > Permalinks > Resave the settings. And finally, what happens if you create another Menu from scratch (test with a couple of items) and synch that Menu? does the issue persists with new menus? Best, |
October 23, 2024 at 12:17 pm #16321636 | |
frankG-4 |
Hi Ilves, yes these strings are all manually added as individual link menu entry. But all current individual links are okay. If I have to synchronize the menu I have to be careful to unselect these Stings. I cleared all settings from your screenshot, but the wrong Menu Sync Entries are still there. Can I get rid of them manually? They are obviously not coming from the database or they are encrypted in the database. |
October 23, 2024 at 9:47 pm #16323672 | |
Ilyes Supporter
Languages: English (English ) French (Français ) Timezone: Pacific/Easter (GMT-05:00) |
Hello, Yes, you should be able to edit these links manually from Appearance > Menus. You can then edit each menu item in the original language and then change the language to do the same to other languages. You could refer to the last section of this documentation on how to manually translate and edit menus : https://wpml.org/documentation/getting-started-guide/translating-menus/#fully-custom-create-menus-manually Best, |
October 24, 2024 at 9:21 am #16325221 | |
frankG-4 |
Hi Ilyes, I think we misunderstand each other. I know how to edit the Menu manually. In the moment I do not have to, because all the links and titles are fine. Every menu entry links to the correct domain. But: When I want to use the synchronize menu function from WPML, there are wrong entries. So I cannot use this function any more - or carefully select the entries I want to synchronize. If I would synchronize everything - what I normally did - I would get lots of wrong entries. And my question is, how to delete these wrong entires at Synchronize Menu. Please have a look at the screenshot. My current Domain is hidden link. Here you see the old staging site domain kruess.coachthemes.com and some of the menu titles are not set. But in the real WP Menu everything is fine. All translations and links are okay. Best, Frank |
October 24, 2024 at 4:56 pm #16327489 | |
Ilyes Supporter
Languages: English (English ) French (Français ) Timezone: Pacific/Easter (GMT-05:00) |
Hello, Oh, sorry for the misunderstanding, in that case, I would like to ask for temporary access to your site’s wp-admin and FTP to investigate the issue further. If you do not see the form below, please do not enter your credentials as they will be publicly exposed: hidden link For your privacy and security, please ensure that you make your reply a private one. Best regards, |
October 25, 2024 at 12:52 pm #16330672 | |
frankG-4 |
Hi, I understand that you like to log in, but the problem is happing at our live site (very frequented) and it's a shop and I am not allowed to grant access to other parties. Would it be an idea, if you tell me which files you need from FTP, that I zip these files and send them to you? Best, Frank |
October 28, 2024 at 3:14 pm #16338458 | |
Ilyes Supporter
Languages: English (English ) French (Français ) Timezone: Pacific/Easter (GMT-05:00) |
Hello, Thank you for your patience, I wanted to double check with our devs, and here is what they said : - These are absolute link/custom URL, which is not taken into consideration by WPML when changed, WPML can only automatically change default "real" URLs or dynamic urls. Best, |
October 28, 2024 at 5:12 pm #16339171 | |
frankG-4 |
Hi thank you for asking your developers. I give you all files from /languages/wpml as zip to download here: I cannot check the files, because I cannot Edit .mo Files with any of my editors and not with Poedit. I saw 3 Files called hauptmenü menu-xxx. This is the name of my main Menü. Maybe you will find the strings here. If you can edit those, "hidden link" has to be replaced with "hidden link". I even checked the string translation, but cannot find strings with "coachthemes". Thanks, Frank |
October 29, 2024 at 7:05 pm #16343975 | |
Ilyes Supporter
Languages: English (English ) French (Français ) Timezone: Pacific/Easter (GMT-05:00) |
Hello, Yes, .mo files cannot be edited, they are compiled files created from .po files. So either we need to check which .po file contains this URL OR we could try the following options under WPML > Support > Troubleshooting : hidden link Please cleanup the Strings table and then regenerate the .mo files. This could help update your MO files to match what you currently have as strings, If that did not help, we would need a full copy of your site if that's possible (or at least a staging access) Please let me know if that helped, |
October 30, 2024 at 11:18 am #16346517 | |
frankG-4 |
Hi Ilyes, Yeah - that was the hint it takes. Now the settings are okay (see Screenshot). That means after a change of the Domain Name I better run these two steps, cause there could be strings with the domain name in mo-files. You can close this ticket now. Thank you very much... Frank |