I have translated my taxonomy vocabularies using the Entity Translation module (tested with alpha 1 and the Apr-08 dev) and the Title module (used to translate the term names- 1.0 alpha 2).

I have a term reference field on the user profile that uses hierarchical select and the dropbox widget to allow multiple selections.

For two+ level deep hierarchies:

When I select a term, the first drop-down menu always shows the terms in English, which is the site's default language. However, if I select one of those terms, the next drop-down menu (second tier) will appear translated properly. The third tier drop-down menu also appears translated properly. The menu for the first tier is incorrectly displayed as the default language rather than the user's language.

Also, once a term is added in the Dropbox, the hierarchy is correct but the first tier term still appears in the default language. Upon saving the profile, the first tier remains in the default language and the rest of the tiers are saved properly in the user's language.

For single level hierarchies using the Dropbox:
The select widget appears in the default language rather than the user's language. However, when a term is added, it is shown correctly in the translated language in the Dropbox view area (unlike the case for two+ level deep hierarchies). Also, it then appears properly after the node is saved.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

ptmkenny’s picture

Example of the problem:
first field shows up in English but second in Japanese

The site should all appear in Japanese, but the first drop-down menu shows up in English. The second shows up properly in Japanese. All of the terms have been translated.

Wim Leers’s picture

Project: Hierarchical Select » Entity Translation
Version: 7.x-3.0-alpha5 » 7.x-1.x-dev
Component: Code » Base system
Assigned: Unassigned » Wim Leers

Moving to the Entity Translation issue queue to gather feedback from their maintainers; please move it back once you've answered it.

Q: How does the Entity Translation deal with Taxonomy term translations compared to the i18n modules?

plach’s picture

Well, ET basically use core field langauge support to provide a different value per language for each field attached to a term (see http://drupal.org/node/1500308 for some more general info). The Title module offers the ability to replace a plain property with a field, thus making it translatable. In the case described in the OP there is a name_field replacing the taxonomy name. i18n_taxonomy instead exploits i18n_string to translate the name and description properties.

plach’s picture

Project: Entity Translation » Hierarchical Select
Version: 7.x-1.x-dev » 7.x-3.0-alpha5
Component: Base system » Code

Moving back as requested.

guillaumev’s picture

Status: Active » Needs review
FileSize
5.77 KB

Here is a patch that should fix this

guillaumev’s picture

New patch, because the last one caused a bug on the taxonomy edit form.

guillaumev’s picture

Issue summary: View changes

add info about title module

flyingkiki’s picture

Issue summary: View changes

Has anyone ever encountered issues as following?

In French content creation page, the hierarchy term reference field shows the French version term label correctly, but after choose on term and click "Add", original version term label (e.g. English term label) displayed under "All selections" area.

claudiu.cristea’s picture

This seems to be the same as in #2252949: Untranslated root level terms. But that fix is straight.

+++ b/modules/hs_taxonomy.module
@@ -1081,7 +1095,18 @@ function _hs_taxonomy_hierarchical_select_terms_to_options($terms) {
+    else {
+      $entity = taxonomy_term_load($term->tid);
+      if ($entity) {

Using single entity load (taxonomy_term_load()) for each term is too expensive. What I did in #2252949: Untranslated root level terms is that I loaded all terms once.

Can you try that fix and see if fit?

stijndmd’s picture

guillaumev's patch 6 causes the same error on term edit form as the number 5 one.
It also doens't fix the issue.

claudiu.cristea's patch that can be found at https://www.drupal.org/node/2252949 works.

claudiu.cristea’s picture

@stijndmd, if you tested #2252949: Untranslated root level terms and that works for you, why not set that to RTBC? :)

Gold’s picture

Status: Needs review » Closed (outdated)

Given the time that has passed and the claim that it has been fixed by the patch on issue #2252949 I'm closing this as outdated. If this is still an issue please reopen and update the description with detailed steps to reproduce.

proweb.ua’s picture

Drupal 7.65
hierarchical_select 7.x-3.0-beta9
title 7.x-1.0-alpha9+25-dev
entity_translation 7.x-1.0

child term is still not translated

patch #5 after manual patching, it works

ajFernandez’s picture

Hi everyone,

I had the same issue as @proweb.ua in #12. After applying the patch #6 manually, it works for me but I still have the issue in the term reference fields in node edit forms. Does this happen to anyone else?

Anyway, I have updated the patch to adapt it to the latest dev release of the module. It is also compatible with the latest stable version of the module (7.x-3.0-beta9).

ajFernandez’s picture

FileSize
5.78 KB

I just updated the patch file to solve some issues with code indents.