Hi,
I think there is a bug in creating a translation of a node. After clicking "create translation", user is redirected to node add page with predefined values of the parent node. But the language remains the same as the current selected language. I think that the interface should switch to language of created node. Otherwise, there are problems with:

- creating menuitems
- pathauto ([lang] points to original lang, not translation!)

So if my current language is "cs", link to create english translation shouldn't be:

http://www.example.com/cs/node/add/novinka?translation=49&language=en

But:

http://www.example.com/<strong>en</strong>/node/add/novinka?translation=49&language=en

Comments

LeisureLarry’s picture

I totally agree with you that not changing the language causes problems with creating menuitems and have fixed this problem for my Drupal 5.2 installation.

Go to your modules folder and in the folder i18n/translation. Open the file translation.module and search for the following line:

$options[] = l(t('create translation'), $createlink, array(), "translation=$node->nid&language=$lang");

Add the following line just above this line:

$createlink = $GLOBALS['base_url'] . '/' . $lang . '/' . $createlink;

Greats from Germany
LeisureLarry

jose reyero’s picture

Category: bug » feature

I find current behaviour quite consitent and it really works as expected. Content and interface language are meant to be independent.

However there's this translation module setting. If you want to propose a patch that takes this into account it will be accepted:
Language Management:
- Interface language depends on content.
- Interface language is independent

jose reyero’s picture

Status: Active » Closed (won't fix)

This won't change for 5.x

TripleEmcoder’s picture