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,
My site is multilingual, i have problems in the breadcrumb (it not display the menu of the current language).
Comment | File | Size | Author |
---|---|---|---|
#12 | 1514830.patch | 791 bytes | RyanPrice |
Comments
Comment #1
latulipeblanche CreditAttribution: latulipeblanche commentedI use Menu Breadcrumb on a multilingual site with two menus with their own language (one menu in English and the other in French) and the breadcrumb changes depending on language.
The administration menu changes also when changing language.
Are you sure that it's the breadcrumb generated by "Menu Breadcrumb" module you have on your site ?
I'm not sure if this can help you but you can always do a drush cc all (clear the cache) and/or refresh and update strings for languages.(admin/config/regional/translate/i18n_string)
Paul
Comment #2
anouHello,
maybe it works fine if you have 2 menus, but if like me you have set your menu on "Translate and Localize. Menu items with language will allow translations. Menu items without language will be localized.", the breadcrumb won't get translated. Only the "home" link gets translated...
I'm still on it to find a solution. If I found one, I'll be glad to share it, but if someone has allready found the solution, I'll be glad to hear from it ;-)
Comment #3
ganagus CreditAttribution: ganagus commentedConfirmed this behavior. I have the same setup where each menu item is only one for two languages, each menu item will only get localized. Only the home menu is translated in breadcrumb, not the trailing menu items.
But I don't use Menu Breadcrumb module, so I think the issue doesn't belong here.
Comment #4
anouI must agree with ganagus. It's true that the translation wasn't functioning on breadcrumb before I installed Menu breadcrumb... Did you manage to find a solution for this issue ?
Comment #5
emorency CreditAttribution: emorency commentedI had the same problem. One menu for 2 languages and translated menu items. To achieve to translate the breadcrum, I had to implement this hook:
Hope this helps !
- Etienne
Comment #6
davemybes CreditAttribution: davemybes commentedUsing the t() wrapper gets the breadcrumbs to translate, but it feels a bit hacky to me. My issue is basically the same, except I have separate menus for each language (3 of them) using ENTITY translation. So each menu actually points to the same node, which causes this module to throw out the title from the default language (English) and not the current one. In other words, its not Entity Translation aware. Not sure how to tackle that one, though.
Comment #7
wranvaud CreditAttribution: wranvaud commentedI'm having this issue too but I have two menus, one for each language, like latulipeblanche.
I'm using adaptive themes and corolla (7.X-2), the menu breadcrumb only works on the default language.
I've activated menu breadcrumb, activated breatdcrumbs in the theme, cleared the cache, updated strings, ran cron (just in case)... I also tried unchecking the english main menu and leaving only translated menus as source for breadcrumbs (this doesn't change a thing actually), I tried erasing the regex in the advanced box and many other things... I'm pretty sure it's not a matter of configuration by now.
I've also checked issues related to the theme http://drupal.org/node/1497224#theme_breadcrumb%28%29
What happens in that on all languages except english, the breadcrumb displays the book outline instead of the menu. I've unchecked the option to use book menus as a source for menu breadcrumbs too without any effect.
Any idea what's going on?
Comment #8
mzwyssig CreditAttribution: mzwyssig commentedSame issue here, with entity translation.
Subscribing.
Comment #9
Anonymous (not verified) CreditAttribution: Anonymous commentedI am not using the /menu Breadcrumb but had the same issue as above. The solution by @emorency helped (thanks) but not fully since it was not using context just plain
t()
.Modifications:
i18n_string_translate()
instead oft()
I am using one menu, translated and localized. And here is the code that worked for me...
This probably should be submitted to the i18n team for review... But for now hope this helps someone... :)
Drupal Developer in Toronto
Comment #10
alejandrov CreditAttribution: alejandrov commentednathan6137, your code works fine but I changed it in this way for prevent undefined index errors :
btw, for new users, I added this function into template.php :)
Comment #11
truyenle CreditAttribution: truyenle commentedNone of these are working for me. I have a site in English / French. When having above, I have breadcrumb is always in French although the site is in English.
Comment #12
RyanPrice CreditAttribution: RyanPrice commented@truyenle - Can you try this patch and let me know if it works for you?
Comment #14
RyanPrice CreditAttribution: RyanPrice commented