I'm using faceted search to display a guided search block with taxonomy terms.
All vocabularies listed in the block have their terms translated into another language (with i18n module).

However, if a user switches languages, the block still displays terms in English (while the taxonomy links in the search results do change to their localized versions).

Is there a way to get the block display translated terms? (as the node)

Thank you.

Comments

amccann’s picture

Are you use CCK Taxonomy? I'm running into the same issue but I have currently set it up using CCK facet.

artem_sokolov’s picture

No, I use core taxonomy module.

amccann’s picture

OK. I was hoping my issue was CCK Taxonomy support.

I will sponsor a getting i18n support into this module if that will help.

artem_sokolov’s picture

Status: Active » Needs review
StatusFileSize
new1.73 KB

I tried to answer the question by reading the code. As far as I could conclude from it, this is no way to get taxonomies translated without patching.

So I wrote a small patch that adds a check (in 3 different places) for i18n module existence and, if the module exists, uses it for translating terms. The patch is against v. 1.35 of the taxonomy_facets.module file.

I tested it on my site (Drupal 6.9 with core taxonomy enabled, i18n module 6.x-1.0, faceted_search 6.x-1.0-beta1) and it seems to work (checked only in a guided search block).

artem_sokolov’s picture

StatusFileSize
new1.89 KB

Sorry, a better one.

David Lesieur’s picture

Status: Needs review » Fixed

Thanks for providing this patch!

I have made some changes, though: removing the call to taxonomy_get_term() (serious performance issue), and making some simplifications.

Committed!

David Lesieur’s picture

I have also committed changes to support vocabulary name localization.

artem_sokolov’s picture

Thank you very much!

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.