This thread is resolved. Here is a description of the problem and solution.
Problem:
The client is experiencing an issue with WPML where embedded links in posts revert to the original English version after saving, despite initially displaying the correct language version.
Solution:
We recommend setting the oEmbed Responses (oembed_cache) to "Translatable" with the option to "use translation if available or fallback to the default language." Instead of using language-specific URL formats, use a universal link format based on the post ID (e.g.,
https://expforex.com/?p=59309
). This should redirect correctly to the appropriate language translation upon saving. However, this solution requires manually updating each article with the new numeric links, which can be labor-intensive.
If this solution does not resolve the issue or seems outdated, or if it does not apply 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 problems persist, please open a new support ticket at WPML support forum 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 17 replies, has 2 voices.
Last updated by Ilyes 1 year, 6 months ago.
Assisted by: Ilyes.
| Author | Posts |
|---|---|
| October 28, 2024 at 3:12 pm #16338346 | |
|
vladislavA-6 |
Background of the issue: Symptoms: Questions: Subject: Issue with WPML and Embed Link Insertion in WordPress Problem Description: Hello! I'm experiencing an issue with WPML and embedding links in the WordPress editor. The problem is as follows: I embed a link within a post, and initially, it displays correctly, selecting the appropriate language version (e.g., hidden link for the Russian version). However, after saving the post, the link often reverts to the original English version (hidden link). This issue is not limited to digital (numeric) links. For instance, when I embed hidden link, it initially shows the correct Russian version. However, after saving, it switches back to the English URL: hidden link. Additionally, on some pages, such as hidden link, content that should appear in Russian (as it’s set up in the code) is displayed in English after saving, even though translations already exist. This inconsistency affects approximately 90% of embedded links, making it difficult to manage multilingual content accurately. Notably, regular text links (not embedded) continue to display the proper language version after saving. Could you please advise on how to resolve this issue or suggest any settings that might stabilize Embed link behavior with language versions? Best regards, |
| October 28, 2024 at 5:00 pm #16339154 | |
|
Ilyes Supporter
Languages: English (English ) French (Français ) Arabic (العربية ) Timezone: Pacific/Easter (GMT-06:00) |
Hello again, This is the ticket where we can continue our conversation, Below you will find a form where you could share a copy of your site or access to staging site. You could use All-in-one WP migration plugin if you'd like to create a copy, in that case, please exclude Media files to reduce the backup size. Also, please share a link of one of the concerned posts. Best, |
| October 29, 2024 at 9:40 am #16341054 | |
|
vladislavA-6 |
Hello, I believe I have identified a potential solution to the issue, but it requires considerable manual effort as it involves updating links across all posts. Here’s the approach I took: I enabled the following setting: 1. oEmbed Responses (oembed_cache) - set to "Translatable" with the option to "use translation if available or fallback to the default language." 2. Now, instead of using the language-specific URL format (e.g., hidden link), I need to use a universal link format based on the post ID, like hidden link. 3. Once saved, this link correctly redirects to the appropriate language translation! The challenge here is that I need to update each article manually with the new numeric links, which is quite labor-intensive. Could you advise if there's a more efficient way to apply this solution site-wide, or if there are alternative methods to automate this process? Thank you for your assistance. |
| October 29, 2024 at 7:30 pm #16344009 | |
|
vladislavA-6 |
Found a new error, when following this link: hidden link the site opens the English version. Although it should open the Ukrainian version! |
| October 29, 2024 at 7:39 pm #16344036 | |
|
Ilyes Supporter
Languages: English (English ) French (Français ) Arabic (العربية ) Timezone: Pacific/Easter (GMT-06:00) |
Hello, Thank you for digging deeper into this, I'm afraid I cannot yet give you a possible solution without debugging your site, For that purpose, we would like to get a copy of your site, I could then debug the issue for you and see how we can make this work with your current workflow, I opened a form below where you can share that, please let me know if that's possible or if you need help with it, Best, |
| October 29, 2024 at 8:45 pm #16344230 | |
|
Ilyes Supporter
Languages: English (English ) French (Français ) Arabic (العربية ) Timezone: Pacific/Easter (GMT-06:00) |
You could use Duplicator or All in one WP migration plugin to export a full backup, |
| October 29, 2024 at 9:00 pm #16344258 | |
|
vladislavA-6 |
Yes, I attached the links above. from the duplicator. |
| October 30, 2024 at 7:20 am #16344994 | |
|
vladislavA-6 |
In general. If you make a link like this hidden link - then it leads to the English version (although it should lead to the Ukrainian version of the site), and if you make it hidden link then it leads to the Ukrainian version of the site. It turns out that the direct short link hidden link does not work, which should lead to a post in Ukrainian (for example. ) |
| October 30, 2024 at 2:19 pm #16347706 | |
|
vladislavA-6 |
Tell me, did you receive my file? |
| October 30, 2024 at 4:55 pm #16348612 | |
|
vladislavA-6 |
Tell me, why is the base growing very quickly? Is that normal? |
| October 30, 2024 at 8:31 pm #16349169 | |
|
vladislavA-6 |
I cleared data from revisions in postmeta, the database decreased by 4 times. And what is stored in the Status databases? DELETE FROM GwB_postmeta WHERE meta_key IN ( 'mfn-builder-revision-update', 'mfn-builder-revision-autosave', 'mfn-builder-revision-revision', 'mfn-builder-revision-backup' ); |
| October 31, 2024 at 1:26 am #16349414 | |
|
Ilyes Supporter
Languages: English (English ) French (Français ) Arabic (العربية ) Timezone: Pacific/Easter (GMT-06:00) |
Hello, I have sent you an access request to access the file, please accept it. FOr the Database, WPML stores languages, translations, country flags, and string translations in separate tables. Here is an overview on our tables : https://wpml.org/documentation/support/wpml-tables/ We actually have a way to optimize these tables and reduce the database size : https://wpml.org/errata/reducing-size-of-icl_translate_job-icl_translate-and-other-wpml-tables/ Best, |
| October 31, 2024 at 12:08 pm #16351262 | |
|
vladislavA-6 |
I opened the console while editing an article and found an error when I try to change the link in EMBED! : (анонімно) @ blocks.min.js?ver=0d232d232463200f5cfd:19 Content generated by `save` function: <p class="">hidden linkhidden link and Conditions</p> Content retrieved from post body: <p class="">hidden link and Conditions</p> |
| November 1, 2024 at 12:10 pm #16354835 | |
|
Ilyes Supporter
Languages: English (English ) French (Français ) Arabic (العربية ) Timezone: Pacific/Easter (GMT-06:00) |
I have send you another request to access the drive folder, I cannot give you a proper answer unless I debug this locally. |
| November 1, 2024 at 2:18 pm #16355170 | |
|
vladislavA-6 |
Hello. Sorry. I'm working on translations again now. That's why I'm not archiving the database yet. I have a few questions so I don't have to create a new topic. 2. How do I copy tags from the English version of the original to the translation? It doesn't copy automatically, I copied the tags manually, but only English tags are shown. And translated tags are not shown. |








