Hi,
I'm using entity translation and title modules for translation. I don't want to create multiple terms for each language.
Having common term for each language, How to show the common tag on all languages and show its translated name if it exists otherwise show its default language name.
| Comment | File | Size | Author |
|---|---|---|---|
| #2 | tagcloud_common_tag_translation.patch | 2.77 KB | Kamlendra |
Comments
Comment #2
Kamlendra commentedI've create a patch to solve this issue.
Patch is for version 7.x-1.10
This patch creates a radio button at tagcloud settings page at /admin/config/content/tagclouds
choosing
option will show the translated name of tags when you are using common terms for each language. With taxonomy terms translatable using entity translation and title module.
Comment #3
joseph.olstadThanks for the patch, some documentation will be required for this patch, looks like field name configuration must match what is in the patch or else a likely error. Great first iteration of a patch to get us going. TODO: make this user friendly. If the field name is not configured we need to gracefully warn the user to what we expect and tell the user where to get full documentation for this type of operation.
Comment #4
Kamlendra commentedHi Joseph,
To test common tags for all language using tagclouds module with patch at #2
I've created the following Step By Step Guide to have common tags for all languages in each node:
1. enable entity translation if it isn't already.
2. enable title module if it isn't already.
3. install and enable tagclouds.
4. Enable translation for taxonomy terms, goto admin/config/regional/entity_translation in TRANSLATABLE ENTITY TYPES select Taxonomy terms.
5. Uncheck Hide language selector for your taxonomy vocabulary at admin/config/regional/entity_translation.
6. edit taxonomy vocabulary and choose translation mode "Localize" (Terms Are Common For All Languages, But Their Name And Description May Be Localized). (if you've enable i18n_taxonomy module enabled).
7. goto admin/structure/taxonomy/tags/fields, click replace link then check "Replace description with a field instance
If this is enabled the description will be replaced with a customizable field that can be translated." This will enable
translation of name field and its machine name will be "name_field".
8. add taxonomy term reference field to basic page content type.
8.1. (options: use any dropdown or autocomplete widget).
8.2. Do not enable translation on taxonomy term reference field as you want the same term for all languages.
9. enable "No Separation Of Tags Per Language, Common Tag To All Languages Is Show As Per Its Translation. "
in admin/config/content/tagclouds (This option will only be available after you've applied patch#2 successfully).
10. Now create test taxonomy term 1 at admin/structure/taxonomy/tags/add click save and translate and add its translation
add some more terms with their translations.
11. Use the newly created terms in basic page content.
12. You will have tags block with name tags in tags at admin/structure/block display this block at your desired region.
13. This block will show the common tags in English or their available translation in any other language.
Comment #5
joseph.olstadGreat work Kamlendra, sorry I haven't been able to review it yet in full , IMHO it would be nice to have this in the next release.
Comment #6
chris matthews commentedThe patch in #2 does not apply to the latest 7.x-1.x development branch, added needs reroll issue tag.
Comment #7
grask0 commentedD7 reached its EOL back in January 2025, and there is no active release for D7 for this module anymore.
Development or support is not planned for D7. All D7-related issues are marked as outdated in a bunch.
If the issue remains relevant for D10+ versions, merge requests with proposed solutions for a new module version (D10+) are welcome in a new follow-up issue.
Thanks!