I would like to find out what would be the best way to define custom textual (not tokens) path for multi-language site and taxonomy terms.
As I can find in UI, per language paths can be defined only for content types (Content Paths section), but not for taxonomy terms, where default and per vocabulary options are available only.
I am using Taxonomy vocabulary set to "Translate. Different terms will be allowed for each language and they can be translated." This is using i18n module and sub modules. And would like to set textual base path for each term depending on it's selected language. For example:
- products_en/[term:i18n-name] - for English version, and;
- products_other/[term:i18n-name] - for particular other language.
With current UI I can not find solution to do it this simple way, only use Tokens (Token module enabled obviously).
One way would be use localized vocabulary name in path generation, but I still do not feel quite comfortable with it, as I use more descriptive names for vocabulary, than needed in URLs. And more for this, I am not aware of any consequences, as I am planning to override display of nodes with views, but still not want to use taxonomy/term/% way (Search API type view is intended).
I would like to achieve this, as I am planning to use Taxonomy Menu module, to let assigned users manage taxonomy categories, still automating correct multi-language path generation per term tied to particular views page. And provide particular vocabulary as a menu in a block. (Currently flat taxonomy terms are considered - without hierarchy.)
Is there a way to achieve this? May be I do not get all the options of Tokens?
Comment | File | Size | Author |
---|---|---|---|
#10 | Screen shot 2013-05-08 at 9.47.10 AM.png | 70.33 KB | wooody |
#10 | Screen shot 2013-05-08 at 9.44.49 AM.png | 31.07 KB | wooody |
#6 | Screen shot 2013-04-30 at 10.39.36 AM.png | 35.59 KB | wooody |
#1 | pathauto-taxonomy_language_patterns-1819206-1.patch | 1.75 KB | peximo |
Comments
Comment #1
peximo CreditAttribution: peximo commentedHello, I need also the same functionality; attached patch should add this feature.
Comment #2
wooody CreditAttribution: wooody commentedHi,,, Are u sure its working... I tried the patch but its not work..!
any help to fix it...
Thanks
Comment #3
wooody CreditAttribution: wooody commentedanyone can help ... just to test this patch and make sure its working or not...
Comment #4
orbmantell CreditAttribution: orbmantell commentedPatch is working for me.
+1 vote to add this functionality!
Comment #5
wooody CreditAttribution: wooody commentedOrbmantell ,, Can u please tell me how its work with u,, I did this on screenshot and the Links still like
site.com/taxonomy/term/28
Comment #6
wooody CreditAttribution: wooody commentedScreenshot here
Comment #7
wooody CreditAttribution: wooody commentedAny help ... :(
Comment #8
wooody CreditAttribution: wooody commentedWhat is the language settings that I need to set for my vocabulary ..
Comment #9
peximo CreditAttribution: peximo commented@wooody: Can you explain better what is your problem? Alias are not generated or they are wrong? Could you write the steps to repeat the problem?
Comment #10
wooody CreditAttribution: wooody commented@peximo Thank you for your reply
I have site with 2 languages ,, And I have vocabulary called ... please see the attached image.
Etikett: for Swedish
Tag: and translated to English
and I have terms for swedish and english too
I did the patch and I can see new input fields in the pattern in path alias.. please see attached image.
and then I delete all alias and bulk update taxonomy .. but its not generate the alias for taxonomy
( No new URL aliases to generate.) and the links like this localhost/taxonomy/term/28
Thank you,
Comment #11
wooody CreditAttribution: wooody commentedAny help to fix this problem :(
Comment #12
pieterdt CreditAttribution: pieterdt commented#1 works for me as well! Thx
edit: the configuration screen works, I can set paths for every language, but when creating new terms in that vocabulary, having a language, their alias is not generated correctly, it is generating the language neutral alias all the time.
Comment #13
ireneb CreditAttribution: ireneb commentedI tested the patch on my site (English/Danish), and it worked. But I also have https://drupal.org/project/pathauto_i18n_taxonomy installed and therefore I had to do the same corrections in the file: pathauto_i18n_taxonomy.module as the patch did in pathauto.pathauto.inc
Then it worked like a charm
Comment #14
quicksketchLet's consolidate this with #290421: pathauto patch to provide localized and entity translated taxonomy through i18n. We've got at least 4 issues covering the same thing (several with patches). That issue has the most traction and working patch. If you'd like to get this in, review that patch.