One of the must-haves when you make a multilingual site is a custom front page for ever language.
There different ways of doing this, but I just discovered the first one I really like. (thanx to Earl Miles!)

If you have i18n set up and panels2 installed, you might want to try this:

The basic English front page
- create content > panel
- choose a single column
- give it a title, choose the language (e.g. English) and give it a teaser.
- click submit and choose 'Panel content'
- click the plus-sign and choose "New custom content"
- give it a title and a body and click "add pane"

You now have an simple panels-node (e.g. node #13) with the Drupal path "en/node/13"

Now comes the good part...

The basic German front page
On "en/node/13" there's a tab that says "translation"!

- click "translation" ("en/node/13/translation")
- In my case it says "German, Not translated, create translation, select node"
- click "create translation"
- choose a single column again
- give it a title, choose the language (this time it's German) and give it another teaser.
- click submit and choose 'Panel content'
- click the plus-sign and choose "New custom content"
- give it a title and a body and click "add pane"

That's all Folks!

Comments

light-blue’s picture

For the life of me, I couldn't make this work with multiple panels for each language-specific home page, so I came up with an alternate solution using views, which simply translates the elements from the main page into the active language. The details are here (http://drupal.org/node/108117#comment-860000), in case it helps you.

cfmcoder’s picture

Make sure that you enable internationalization of the panel node by going to admin/content/types/panel and setting the Multilingual Content option to Normal or Extended.

Noira’s picture

I got it!

The key is to set up custom blocks first, like "apple" and "apfel", set them a specific visibility - in my case it was only "en/home" or "cs/home", and then add them to the panel that is aliased as "home" in both languages.

Beware that when adding a custom block to the panel page, you must tick the feature "apply visibility settings", or it does not work. This way you can set up a single panel page filled with custom blocks, and different blocks will appear on various language versions of the site. (http://adf.davnyobycej.cz)

phicarre’s picture

OK but the title of the panel is not translated !

yolene’s picture

Thanks, this is nice but it doesn't explain how to make it frontpage ... i've been fighting with various solutions and finally found this out :
1) i created from "create conte>panels" a panel view, and then i created a translation for it (careful : don't forget to enable in the multilingual module translation for content type=panel)
2) i set for the french (my language) panel an alternative url : fr/home
3) i set for the english panel an alternative url : en/home
Then i go to site configuration>site information , and i set the front page from the default "node" value to the new relevant value "home" (without /fr or /en : this will be managed automatically by the i18n module)

It works and it's simple (and i can't believe i went through 10 other ways to do that and got stuck with it ;-) )

I hope it can help some other Drupalers

intyms’s picture

It works also with the following settings:
1)The alternative url is the same for all languages. I write just "home".
Other settings:
2) Language negotiation: "Path prefix with language fallback" (/admin/settings/language/configure)
3) Content selection mode: "All content. No language conditions apply." (/admin/settings/language/i18n)

Alexander Allen’s picture

This applies to panel nodes. Regular panels cannot be created with the create content page, they must be created using the admin->panels interface.

unrev.org’s picture

I am not sure if this is something new in i18n, but the very simplest way I have found to get two different home pages that show only content in the chosen language is to:

At /admin/settings/language/i18n - select the option "Only Current Language" in the "Content Selection" area.

That's it! This keeps Drupal's default front page functionality and shows, therefore, the latest content added (in the chosen language) as well as anything that has been "Promote(d) to Front Page".

Of course, this means you'll need to have some kind of content for both languages. But it's really simple, and no extra modules needed :)

In order to get from the default language's homepage (/node) to the other language(s), [e.g. /pl or /de], you'll either have to have the translation block showing or have language flags or names somewhere (perhaps built into the theme or Primary Links) easily visible for users to click on.

I spent a lot of time making views, panels, etc, and this turned out to be so quick and simple, and harnesses the natural power of a Drupal front page (/node)!

If you want a custom homepage that is not like Drupal's front page is by default, then you'll want to use Panels as mentioned in this thread.