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.
I can not get the breadcrumbs to display with my child theme. They appear correctly when using the bootstrap theme. When the child theme is set, the bootstrap_preprocess function in bootstrap.theme is never called with the "breadcrumb" $hook. I have breadcrumbs enabled. Any ideas on what might be causing this?
Comment | File | Size | Author |
---|
Comments
Comment #2
markhalliwellMy guess is that the site breadcrumbs aren't being constructed properly. They work fine with breadcrumbs provided by core.
Comment #3
ewing.rj@gmail.com CreditAttribution: ewing.rj@gmail.com commentedI tried creating a new child theme, as well as reinstalling bootstrap theme and it still doesn't work.
Did it work on non-admin areas for you?
Any ideas what might be causing it?
Comment #4
ewing.rj@gmail.com CreditAttribution: ewing.rj@gmail.com commentedIs there something in the child theme that would prevent
function bootstrap_preprocess(&$variables, $hook, $info)
being called with $hook = "breadcrumb"? In my child theme, $hook is never "breadcrumb", but when using the bootstrap theme, the above function gets called with $hook = "breadcrumb".
What determines the $hook? It seems like some setting is being ignored
Comment #5
Majdi CreditAttribution: Majdi as a volunteer commented@ewing.rj I think you missing renaming yml files under config directory of your child theme, rename with your theme name and update the child theme settings with breadcrumb then it should be visible.
Comment #6
akupaka CreditAttribution: akupaka commentedI'm not sure because of a lack of experience, but it seems that until "Show 'Home' breadcrumb link" checkbox is set in theme's settings (Components/Breadcrumbs) function preprocessVariables in Bootstrap/src/Plugin/Preprocess/Breadcrumb.php won't set breadcrumb variable used in Twig templates.
Comment #7
dureaghin CreditAttribution: dureaghin commentedSame issue, I can not get breadcrumbs to display properly child titles on my sub-theme. For example, this is my menu structure:
Current:
- Home
--Categories (I see this: Home/Categories)
---Category (I see this: Home/Category)
----SubCategory (I see this: Home/SubCategory)
Should be:
- Home
--Categories (I see this: Home/Categories)
---Category (I see this: Home/Categories/Category)
----SubCategory (I see this: Home/Categories/SubCategory)
Comment #8
Tsegaye CreditAttribution: Tsegaye commentedIt look me few hours to make them work. I was on D8 (8.6.1), created subtheme from Bootstrap 8.x-3.12. They did’t show up. In the sub theme bootstrap settings in the admin, I had to check and uncheck the components -> breadcrumbs options (Show ‘Home’ breadcrumb link, show current page title at end) and cleared registry. Then, it showed up.
Comment #9
srijeeta CreditAttribution: srijeeta commentedhttps://www.drupal.org/project/bootstrap/issues/2856966#comment-12784969
Worked for me!
Comment #10
markhalliwellFTR, #2875276: Breadcrumbs disappears when starting with front-page after cache rebuild (for anonymous user). was just committed which may help.