Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Hi there, this is basically a follow up from #1070256: Localize terms show always the default language.
I still have the issue that my taxonomy terms are not translated on node/add or node/edit.. The terms are in English originally and then translated to French.. I can see the translations in the translation interface, but even if I go to the "list terms" in the taxonomy, they're not translated. Only on the node view page they are..
Any help would be appreciated.
Cheers
Comments
Comment #1
Jose Reyero CreditAttribution: Jose Reyero commentedWe are not translating them on taxonomy pages. For node/view, node/edit you need to choose the right field widgets (read 'Translated', 'Localized') and use the right language page.
Comment #2
arski CreditAttribution: arski commentedI am, and they're working perfectly on view, but not on edit/add.. let me know if/what further details I can provide to help.
Comment #3
Jose Reyero CreditAttribution: Jose Reyero commentedWe need to know:
- Vocabulary settings (i18n)
- Field and widget settings
A screenshot would help too.
Comment #4
arski CreditAttribution: arski commentedvocabulary is set to "Localize. Terms are common for all languages, but their name and description may be localized. "
Field is a "term reference", "select list" widget.
Field display setting set to "link (localized)" - I tried "plain text (localized)" too but im pretty sure this option has no effect on the node/edit page.
The site is a 2-language site, with default English and 2nd language French. The terms are added in English and translated in the taxonomy interface, and also if I search for the term string via string translation interface..
Let me know if you need anything else.
Comment #5
Jose Reyero CreditAttribution: Jose Reyero commentedWhich language are you editing the node in?
Comment #6
arski CreditAttribution: arski commentedtried both, i.e. switching the site language between english-french and editing the node. all the field names and description texts etc. all translate correctly, so the language is indeed switched, though the taxonomy term values are not.
Comment #7
ttapada CreditAttribution: ttapada commentedSame problem here.
In my case, I've installed Drupapl in English, added portuguese, and now trying to support mulitlanguage site.
Not working.
Localized terms are only shown in its original; never get translated either in content creation or exposed filters.
Comment #8
Mschudders CreditAttribution: Mschudders commented+1
Comment #9
arski CreditAttribution: arski commentedthe issue has disappeared for me in 1.4, don't think anything else was changed on the site :x
Comment #10
jdanthinne CreditAttribution: jdanthinne commentedI've this problem as well…
When I create a node in a language different than the one I'm currently working in, the language assigned to the terms is the one from the admin, and not the language I've chosen when creating the node (say I create a french node from the english admin, then the terms are considered english and not french, which is wrong…).
I'm using a vocabulary with mode = Translate.
Comment #11
Jose Reyero CreditAttribution: Jose Reyero commentedMaybe using 'Administration Language' module?
Comment #12
Jose Reyero CreditAttribution: Jose Reyero commentedAnother related issue may be #1601828: Improve Content selection, restrict queries using it, decouple it from 'access' not using it for multiple entity loading.
Comment #13
pmusaraj CreditAttribution: pmusaraj commentedI'm running into this issue as well, and it's a considerable problem. It happens on vocabularies that are either Localized or translated. Is it not possible at all for the term language on the edit screen to be same as the node's language?
Comment #14
pmusaraj CreditAttribution: pmusaraj commentedI looked into this issue in more detail, and I think I have come up with a solution.
So, to clarify, the problem affects sites where in i18n's content selection options (admin/config/regional/i18n/select) are checked for taxonomy and node. These force the translated terms and the node references to use the interface language, and not the node language. If these settings are turned off, all terms are made available, i.e. for both languages. This issue also affects node reference fields.
I have fixed this using a data_query_alter that I put in a custom module, but it should likely be done inside i18nselect. I.e. if i18nselect detects that the current node is assigned to a specific language, it should alter queries to use that language, and disregard the interface language.
Here's the code for the terms that I put in a custom module:
Feedback is more than welcome. I would be happy to provide this as a patch, if deemed reasonable by the maintainer(s). (It would be my first patch, but I'm keen on doing it.)
Comment #15
pav CreditAttribution: pav commented+1
I have a vocabulary with translation mode set to "Localize". When I translate the name and description of the vocabulary or individual terms, the system seems to remember it - "Status" changes to "translated" and a translated title is displayed. But this is not displayed on any other page - not in widgets, not on the term pages, nowhere at all! When I navigate to the term page, I get it in the default English, when I use the dropdown selector in content creation screens ditto...
Have I missed a setting somewhere?
I am on Drupal 7.14 and i18n 7.x-1.5. THe language detection method is set to "URL" and "Default".
Comment #16
batigol CreditAttribution: batigol commentedSame problem here
Comment #17
lmeurs CreditAttribution: lmeurs commentedSame here, but the terms are in main language English only when the widget is set to "Autocomplete term widget (tagging)", when set to "Select list" or "Check boxes/Radio buttons" the localized terms appear.
Comment #18
Jose Reyero CreditAttribution: Jose Reyero commentedAutocomplete terms are just not translated because that is not implemented, see #1085190: Make taxonomy autocompletion work / tagging / block tagging ?
Comment #19
webdrips CreditAttribution: webdrips commented@Jose, forgive me, but I don't understand how this is a duplicate of the autocomplete issue.
The original poster indicated an issue with select, not autocomplete. I'm seeing the issue with checkboxes, and otherwise have the same settings as #4.
When I attempt to add a term when the language is set to the secondary language, I'm only seeing the English terms. After the node is saved, the selected terms are displayed with the text properly translated.
Comment #20
batigol CreditAttribution: batigol commentedStrange thing: i18n 1.5 and drupal 7.15
When i create a news (node) and add few tags to it - everything is fine. But when I translate this news to other language then all tags are wrong linked to other language (I HAVE translated all tags).
But when i create a news, translate it and in translation I use DIFFERENT tags then in source translation news, their links are fine...
The think there is a problem - when adding taxonomy terms to the content. It seems that when you have 2 tags in different language but they have the same name [for example you translate computer (en) to computer (fr)] then link to this term is broken. Drupal choose wrong tag, it's not looking at you actual language that you adding content with.
So something is fu#@ up here. It also seems that translated Vocabulary Name is not used in translated taxonomy links - the default language name is used.
I'm gona test it with i18n 1.7 and see if the problem repeat it self.EDIT: Same thing with i18n 1.7
Comment #21
webdrips CreditAttribution: webdrips commentedSetting this back to bug since I believe this issue still persists (see #19).
Comment #22
batigol CreditAttribution: batigol commentedSimilar topic - http://drupal.org/node/1812760
Comment #23
airstarh CreditAttribution: airstarh commentedCopy-paste from
http://drupal.org/node/1070256#comment-7258638
(still do not have solution)
I think I tried everything here and in all Internet at all.
Nothing is working.
BTW:
I am also confused, that on admin page when I cross:
Structure -> Content types -> I see all Content types on the language I've created them, despite on use of translating their names via Entity Translating and Title modules.
Thanks God, there are no bugs on front end. But another language on node creating or edditting seems very unprofessional.
So, what about #26 - I have not found these admin settings to...
So,,, Subscribe )))
Comment #24
plachIf you are using an entity reference widget you need #2013849-4: Term names are not translated.
Comment #25
pixelpreview@gmail.com CreditAttribution: pixelpreview@gmail.com commentedI have the same problem, I have read a lot of posts and I don't find solution to this problem ... someone can show me the right way ???
I have a site in 3 languages
url language detection is active
I have a localized vocabulary (all terms are translated)
when I edit a node at LANG/node/add/article or LANG/nid/edit, the select /autocomplete field for term reference is always in default language (english) :(
After one year, no solutions ?
Comment #26
pwiniacki CreditAttribution: pwiniacki commented@pixelpreview it's good that you can use auto-complete cause it was bugged before if I remember correctly :) and only option was to check(form) correct tags (LOT of clicks).
You need to change language to language the node is written in and then edit it - add tags. Otherwise it will not work. VERY frustrating, agree.
Comment #27
pixelpreview@gmail.com CreditAttribution: pixelpreview@gmail.com commentedthank you @pwiniacki, I have found a solution
I active the select multilingual module, check taxonomy select in it admin page.
I use a little hook to modify the link when we click in a translate link
When I create a node in DE/node/add/article
the select is in DE with a localized vocabulary
when I click on the translate tab (the current language is DE) and choose to create a translation in FR for example, with my hook, the url contains ...FR/node/add/topic?destination=node/3601/translate&translation=3601&target=fr ... in place of .... DE/node/add/topic?destination=node/3601/translate&translation=3601&target=fr
Thus the select show me my localized terms in DE :) and my users are happy.
I think that the module works like that before and that these functionality has been removed from the team. before, each translate link redirect with the language prefix from the translation that you want create and not the current language like now.
Comment #28
gonssalRead this for an easy fix: #2418629: Make taxonomy_get_tree load entities by default
It's a core module modification, so you will have to apply everytime you update. The good part is that it's just changing a FALSE for a TRUE.
Another option is using the Taxonomy Term Reference Tree Widget module.
Comment #29
ptmkenny CreditAttribution: ptmkenny commentedComment #30
evets33 CreditAttribution: evets33 commentedHello pixelpreview
I'm interested about your hook. Can you show me an example please
Thank you
Comment #31
PMorris CreditAttribution: PMorris commentedThis is still an issue. Taxonomy terms are not displaying in the correct node language. The terms are instead getting switched to whichever language is set in the site language switcher. Which results in a list of terms with uncheck fields in the wrong language.
In i18n /admin/config/regional/i18n/select
I have "Select taxonomy terms by language" turned on