To make this work one must translate the node and add a new menu item to that node.

Do not translate a menu item as that sticks to the untranslated node.

See #6.

Comments

clemens.tolboom’s picture

Title: Allow for more then just one single page » Allow for multilingual support

I did not succeed in creating a test for multilingual.

What I did was:

drush site-install --yes
drush dl devel single_page_website i18n l10n_update

drush pm-enable translation locale l10n_update i18n_menu i18n_node i18n_select

On admin/config/regional/language enabled French Dutch and English
On admin/config/regional/language/configure enabled URL
On admin/config/regional/language/configure/url set to path prefix

Now created a (translatable) Story in English and Translated that into French and Dutch.

Now the normal front page shows

/ : the English node
/fr : the French node
/nl : the Dutch node

Next drush pm-enable single_page_website has not much effect as the main menu has no entries.

But what item should we add to the menu? It would be nice to add all to the main menu but that will show all nodes.

Switching between the language does change the UI but nl/single_page not much happened.

As we do not have much content we probably are better of having more menu's. One for each language.

Did I miss something?

To generate your list use

 drush @drupal.d7 pm-list --no-core --status=enabled --pipe | xargs
devel devel_generate l10n_update i18n i18n_menu i18n_node i18n_select i18n_string i18n_translation libraries module_filter variable
clemens.tolboom’s picture

Status: Active » Needs review
StatusFileSize
new1.36 KB

Yes is missed something :p

On admin/structure/menu/manage/main-menu/edit
- Select "Translate and Localize. ... " for Multilingual options

Now navigating to /nl shows the expected Dutch node.

All nodes are added to the main menu.

Attached patch makes it work.

clemens.tolboom’s picture

Status: Needs review » Fixed

I've retested and it works like a charm.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

clemens.tolboom’s picture

Assigned: Unassigned » clemens.tolboom
Status: Closed (fixed) » Active
clemens.tolboom’s picture

Status: Active » Fixed

I reopened this issue as it was a little unclear how this support works.

But this is out of the Drupal box.

When one translates a node it must get a new menu item that is a new node has a separate menu item.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

Anonymous’s picture

Issue summary: View changes

Updated issue summary.