Migrating from static HTMLs with i18n

Some key points in migrating static HTML pages to Drupal 7 with the full i18n (Internationalization) features incorporated are described.
Drupal's i18n feature is powerful and has a great flexibility. However the flip-side of the coin is it is not that easy to understand how it works, partly because it heavily depends on your configuration. Also, it may not match well the suffix-based language negotiation by the Apache server for the static HTML pages, and so the migration of such static HTML sites to Drupal is not quite straightforward.

Import content and its translations from CSV (managing entityreference field)

In this page, we will see how to handle an entityreference field in content type 2 referencing a content of content type 1 without having the id of the target, only its title.

And of course in all the languages we want.


For the main language import, we will be using an entityfieldquery to get the id of the content of content type 1 in the main language.
For the other languages import, we will use the main language import to be sure of the id of the target.

Import content and its translations from CSV

Using migrate-7.x-2.6-RC1.

The main purpose of this cookbook is to show how to import one content type in as many languages as you want using CSV import.

It assumes that you have one csv file per language, that each is in the csv format, and that the content for all its translations are at the same line.

Force using "" to avoid problem with language like russian chinese, japanese, arabic, etc...

The translation file appears to have a missing or malformed header

It seems like my installation doesn't allow my .po file to be imported.

Everytime I try to import a .po file I'm getting the following error:

The translation file [some_language.po] appears to have a missing or malformed header.

What kind of header is it referring to? My .po file simply consists of strings, nothing more:

msgid "My Settings"
msgstr "Meine Einstellungen"

msgid "Logout"
msgstr "Ausloggen"

Taxonomy upgrade extras: 


Subscribe with RSS Subscribe to RSS - i18n