This might sound like crazy, but I had to import about 3-4000 entries from a non-WP site to a… well, WP site. The problem, however, was that the site was multilanguage, and half of these posts were in different language. Using WPML plugin sounds like a great idea since I used it already on several other sites and I had no problem at all ($80 well spent!).
However, even if the plugin is just great for adding new content, processing old content/imports with is a major PITA. Mostly because their support forum staff might not know what to say sometimes.
I guess anyone knows how to insert a WP post, right?
// it's important to assign the returned value - that is the ID of the newly inserted post - to a variable
$new_post = wp_insert_post( array(
'post_title' => "Entry Title",
'post_type' => 'my_post_type',
'post_status' => 'publish'
But, if you want to programmatically insert a new post in a different language than default, you must use
wpml_update_translatable_content(), wich is contained into
wpml-api.php: Citeste mai departe »