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.
When I have i18nviews installed - and get taxonomy: term (using views) - the [name] is translated which is fine for display - but I also need to create a link to this taxonomy (using taxonomy term, not tid) - and that link needs the original (untranslated) name to work :(
I'd suggest that when i18nviews translated [name] (and others) - it also adds an [name_orig] or similar.
Comment | File | Size | Author |
---|---|---|---|
#1 | i18nviews_taxonomy_term_preserve_original_name-824696-1.patch | 1.17 KB | Cyberwolf |
Comments
Comment #1
Cyberwolf CreditAttribution: Cyberwolf commentedThe actual problem is that the field handler changes the values retrieved by the Views query. See i18nviews_handler_field_taxonomy_term_name::pre_render():
It shouldn't change the original value, instead it should render the translated value in the render() method. Attached is a patch that fixes this for the term name.
Probably other stuff needs fixing as well, like the term description.
Comment #2
dawehnerThis seems to be a duplicate of #1283024: Translation overrides field values