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 thread is resolved. Here is a description of the problem and solution.

Problem: I am developing multilanguage site, and I have to get know the WPML. For example: Importing translations of thousands of custom post types. In this case I make copy of each post, assign them the same trid in icl_translation table, and finally update the post_title and post_content in database to the foreign language.

Solution: Use WP All Import plugin to make this easier. You can have a look at this article https://wpml.org/documentation/related-projects/wpml-all-import-plugin-website-import-with-wpml/.

This topic contains 6 replies, has 2 voices.

Last updated by zsoltE-2 2 months ago.

Assigned support staff: Radu.

Author Posts
August 10, 2019 at 5:30 am #4374793

zsoltE-2

Hi,
Would you please tell me, where can i find a documentation about global $sitepress class?
Regards, Zsolt

August 12, 2019 at 5:29 am #4378449

Radu
Supporter

Languages: English (English )

Timezone: Europe/Bucharest (GMT+03:00)

Hey Zsolt,

Can you give me a few more details about why do you need a documentation for $global, please? Right now, we don't have anything like this because we didn't find it being helpful. We are trying to create articles with specific topics (instead of generic ones) because we find them more helpful. However, if you have any question about this variable or maybe need some advice about how you can create something, please let me know so I can give you at least some tips, if not the right solution.

Thanks,
Radu

August 12, 2019 at 6:46 am #4378621

zsoltE-2

I am developing multilanguage site, and I have to get know the WPML.

For example: Importing translations of thousands of custom post types. In this case I make
copy of each post, assign them the same trid in icl_translation table, and finally update the post_title and post_content in database to the foreign language.

Now I am using core WP functions and database queries.

It would be much better to use WPML's methods if is there any.

Regards, Zsolt

August 13, 2019 at 11:51 am #4387547

Radu
Supporter

Languages: English (English )

Timezone: Europe/Bucharest (GMT+03:00)

Hey Zsolt,

The only thing that I can think of it so use WP All Import plugin to make this easier. You can have a look at this article https://wpml.org/documentation/related-projects/wpml-all-import-plugin-website-import-with-wpml/ in order to find a few more details about it. We know that there are a lot of users that want to import the content easier and that's why we tried to make everything work flawlessly between WP All Import and WPML.

Thanks,
Radu

August 13, 2019 at 12:07 pm #4387767

zsoltE-2

Hi,
Yes, but as I know it does not work with custom post_types, custom fields and custom taxonomies.
Is this information correct?
Regards, Zsolt

August 14, 2019 at 8:11 am #4393199

Radu
Supporter

Languages: English (English )

Timezone: Europe/Bucharest (GMT+03:00)

Hey Zsolt,

You can import post types too, as far as I know. As you can see here https://wpml.org/documentation/related-projects/wpml-all-import-plugin-website-import-with-wpml/#how-to-import-posts, we are mentioning Importing posts (or other post types) . I think that all you have to do is check the documentation of WP All Import and see how you can import post types instead of simple posts.

Thanks,
Radu

August 15, 2019 at 1:05 pm #4400913

zsoltE-2

I'll try. Thank you for your support.