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.
Is it possible to translate "Home" reference title from this module with i18n?
Comment | File | Size | Author |
---|---|---|---|
#13 | custom_breadcrumbs-home-breadcrumb-504400-2.patch | 1.29 KB | kalis1 |
#11 | custom_breadcrumbs-home-breadcrumb-504400-1.patch | 1.29 KB | kalis1 |
#10 | custom_breadcrumbs-home-breadcrumb-504400-0.patch | 1.85 KB | sepehr.sadatifar |
Comments
Comment #1
blecheimer CreditAttribution: blecheimer commentedPut this in your settings.php
so you can change it per language in http://yoursite.com/#lang-prefix#/admin/settings/custom-breadcrumbs
Comment #2
hamsterbacke42 CreditAttribution: hamsterbacke42 commentedthat worked for me thanks
Comment #3
MGN CreditAttribution: MGN commentedComment #5
MGN CreditAttribution: MGN commented@hamsterbacke82 or @blecheimer , can you verify that this still works with the latest 6.x-2.x-dev? Please see the bug report at #647570: 'Home' breadcrumb i18n not working. It would help to have this confirmed.
Thanks
Comment #6
tomsm CreditAttribution: tomsm commentedsubscribing...
Comment #7
blecheimer CreditAttribution: blecheimer commentedSorry for the late answer I have Custom Breadcrumbs 6.x-2.0-beta2 and it works
Comment #8
blecheimer CreditAttribution: blecheimer commentedComment #9
xalexas CreditAttribution: xalexas commentedaaaaaah thanks a million for this! It worked!
Comment #10
sepehr.sadatifar CreditAttribution: sepehr.sadatifar commentedI've made a patch that simply wrap 'custom_breadcrumb_home' variable used for 'home' text in 't' function so it possible to be translated without using i18n variables.
Comment #11
kalis1Thank you @sepehrmm ! I've adapted your patch for the 7.x-2.x-dev version.
Comment #12
sepehr.sadatifar CreditAttribution: sepehr.sadatifar commentedtnx @kalis1 , I've forgot to patch 7.x-dev.
I've contacted MGN for considering to apply these patches.
Comment #13
kalis1Here's another patch for the 7.x-2.x-dev version, with a slight modification : I've chosen not to translate the default value for custom_breadcrumb_home in the admin settings form, neither translate the whole value like in my previous patch. It was causing a bug, as if the administrator was validating the form in a language other than english, the registered value in database was changed from "Home" to its translation.
Comment #14
Jibus CreditAttribution: Jibus commentedAccording to http://drupal.org/node/299085, it seems that is the proper way to wrap the variable_get() through t()
#13 works perfect ! Thanks
Comment #15
Jibus CreditAttribution: Jibus commentedComment #16
kunago CreditAttribution: kunago commentedNice. The patch in #13 fixed the problem on my site as well.
Please commit the patch.
Comment #17
Sk8erPeter CreditAttribution: Sk8erPeter commentedThe patch in #1 on http://drupal.org/node/1320056 worked for me perfectly.
I also attached some screenshots to make it clear how to do the translation.
Comment #18
colanMarking as a duplicate of #1320056: A small patch to add the home variable to i18n variables for Administrator translation as that seems to be the proper way of handing this (even though this issue is older).