« Precios dispares en supermercados por productos electrónicos chinos clónicos Generate Code 128 barcodes from excel »
Posted on: Wednesday, June 3, 2009 at 23:57 pm
programming.
Puedes seguir las respuestas de esta entrada a traves de l feed RSS 2.0.
Puedes dejar una respuesta, o trackback desde tu propio sitio.
Update posts language after installing WPML plugin for wordpress
June
3
WPML is a plugin that enables a worpress site to write post in different languages. You only have to install the plugin and all works.. wel not all. If you already have lot of articles written in your language, the main page of your site will show anything due that there is no pages with that language. However, you can execute a small SQL sentence to solve this problem, here we go:
INSERT INTO wp_icl_translations(element_type, element_id, trid, language_code) SELECT 'post', `ID`, 1, "es" FROM `wp_posts` WHERE `post_status`="publish"
and for the categories also:
INSERT INTO wp_icl_translations(element_type, element_id, trid, language_code) SELECT 'category', `term_taxonomy_id`, 0, "es" FROM `wp_term_taxonomy` WHERE `taxonomy`="category";
and last, make some cleaning tasks:
UPDATE `wp_icl_translations` SET `source_language_code` = ""
* Replace the “es” string with the appropriate language.
Posted on: Wednesday, June 3, 2009 at 23:57 pm
programming. Puedes seguir las respuestas de esta entrada a traves de l feed RSS 2.0.
Puedes dejar una respuesta, o trackback desde tu propio sitio.










Very nice writeup. We’re planning to add some multilingual import to WPML, which will allow attaching existing translations to each other. Meaning, you’ll be able to say “This post is the Spanish translation of OTHER_POST”.
This way, if you’ve already got multilingual contents arranged in different categories, you’ll be able to associate between them.
[Responder]
sucotronic Reply:
June 7th, 2009 at 23:37 pm
@Amir Helzer, nice also to hear about new features, but what we need is better support to add the plugin to blogs that already have contents.
[Responder]
Amir Helzer Reply:
June 7th, 2009 at 23:44 pm
Best is to open a new issue in our forum and we can follow up on it.
http://forum.wpml.org
You can describe how to existing contents are organized and we’ll see how they can be imported systematically.
As you wrote in your post, the wp_icl_translations table needs to be manipulated. The thing is, you need to do it so that contents in different languages are associated to the same translation group. This way, they appear as translations of each other.
[Responder]