I understand the issue you're having. Could you please confirm that the product you mentioned (Tuta absoluta) in the (ES, PT) text is translated into other languages? Additionally, upon inspection, I noticed that the switcher at the top is added via the "GTranslate" plugin. It is recommended to use only one translation plugin as multiple translation plugins can cause inconsistency in translation.
Could you please integrate the WPML language switcher, confirm that all linked pages/posts are translated into other languages using WPML, and then check again?
After translating the pages/posts, you may need to scan and adjust the link target. To do so, please go to WPML > Settings and scroll down to the "Translate link target" section. After that, click on "Scan now and adjust links".
Please let me know the update. I'll be happy to help if you need further assistance in this matter.
Yes, (Tuta absoluta) in the (ES, PT) is translated into all the languages.
We are not using the GTranslate, we have created our own switcher, the class name is only "g_translate"(don't confuse with this).
We have do the scan multiple time, but the links are generated incorrectly.
Also, FYI, in the site we have used URL rewriting, and the links are generated incorrectly. Below an example, I think is this something with URL rewrite that WPML is not handling correctly.
Generated Target URL : hidden link
Actual URL: hidden link
add_action(
'init', function () {
add_rewrite_tag('%id%', '([^&]+)');
}
);
add_filter(
'generate_rewrite_rules', function ($wp_rewrite) {
Upon reviewing the details you've provided, it appears that the issue you're encountering may stem from custom modifications made to the URL structure. To isolate and identify the root cause, I kindly ask that you revert any custom adjustments related to the URL settings to their original state and then reassess the situation.
Additionally, to further remove any potential conflicts, I recommend temporarily switching to a default WordPress theme, such as "Twenty Twenty-One." After making this change, please proceed to update the translation once more and check if the issue persists.
It's important to note that custom code alterations can occasionally lead to unexpected behavior. Given that our support scope does not extend to issues arising directly from custom coding, this initial step of eliminating custom changes or checking by switching to a default theme is important for pinpointing the issue.
If the problem is resolved after these adjustments, it would suggest that the custom changes were indeed the cause. If the issue remains, however, we can explore other potential factors together.
Let me know the results of these tests, or if you require any further assistance throughout this process. Your cooperation and understanding are greatly appreciated as we work towards a resolution.
Best regards,
Prosenjit
The topic ‘[Closed] Translated Link taget for non-english languages are not correctly generated’ is closed to new replies.