Skip Navigation

This thread is resolved. Here is a description of the problem and solution.

Problem:
The client needed a workaround to import translations for secondary language posts without creating duplicates of the default language posts, which already have SEO traffic and backlinks.
Solution:
We explained that it is not possible to directly import translations to existing content as WP All Import requires the unique identifier to connect translated posts with their corresponding default language post. We recommended the following steps:
1. Export the default language content.
2. Import it back with the correct information.
3. Proceed with importing the second language.
We also provided documentation for further guidance:

If there are not too many posts to handle, we suggested connecting them manually or using our WPML hooks:

If this solution does not seem relevant, 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.

This topic contains 3 replies, has 2 voices.

Last updated by Dražen 1 year, 4 months ago.

Assisted by: Dražen.

Author Posts
February 1, 2024 at 3:10 pm #15255562

cagriS-3

Tell us what you are trying to do?

I am importing translations of posts in the main language.
But the translated posts and posts in main language doesn't get tied to each other.

Is there any documentation that you are following?

I followed this documentation: https://wpml.org/documentation/related-projects/wpml-all-import-plugin-website-import-with-wpml/#importing-content-in-multiple-languages

Is there a similar example that we can see?

For example, I imported this post in German:
hidden link

As a translation of this post in English:
hidden link

The post in German doesn't show up as the English post's translation.

What is the link to your site?
hidden link

February 2, 2024 at 8:38 am #15258149

Dražen
Supporter

Languages: English (English )

Timezone: Europe/Zagreb (GMT+02:00)

Hello,

thanks for contacting us.

You can not directly import translation to existing content, it will not work. You need to import the default language, following our docs, then import 2nd language. In this case, you can export the default language and then import it back with the correct info and then proceed with 2nd language.

Because WP All Import relies on the unique identifier to connect translated posts with their corresponding default language post, you cannot upload the secondary language file to add translations to pre-existing default language content. If you do this, WP All Import will not know which posts the translations belong to.

Please check the following documentation:
- https://wpml.org/documentation/related-projects/wpml-all-import-plugin-website-import-with-wpml/importing-multiple-languages-with-wp-all-import-and-wpml/#adding-translations-when-the-default-language-content-already-exists-on-the-site

Let me know if any doubts.

Regards,
Drazen

February 2, 2024 at 8:59 am #15258195

cagriS-3

Hi Drazen, thanks for your reply.

Creating duplicates of the default language posts would be very problematic for me since the original posts already gained backlinks from other websites, and they have SEO traffic.

Can I do a workaround for this?

Can I get the unique identifier of the default language post and then set the same unique identifier to the secondary language posts?

I can make changes to the database table values, etc. if needed.

Thanks in advance,
Cagri

February 2, 2024 at 9:20 am #15258234

Dražen
Supporter

Languages: English (English )

Timezone: Europe/Zagreb (GMT+02:00)

Hello Cagri,

I understand, but I am afraid there is no solution of box for this. WP All Import and WPML need default import to be connected to 2nd language import.

The best I can suggest is connecting manually if there are not too many or doing so via our WPML hook.

- https://wpml.org/faq/how-to-link-already-translated-pages/
- https://wpml.org/wpml-hook/wpml_set_element_language_details/

Hope this helps.

Regards,
Drazen

February 5, 2024 at 9:45 am #15265039

cagriS-3

Hi Drazen,

Thanks for the suggestions. I managed to make it work with the WPML hook.

Best,