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.
blogtitle doesn't replace the blog title in breadcrumbs at the top of blog nodes. See the highlighted area in the screenshot for an example.
The attached patch fixes this. It assumes that blogtitle_get_blog_title() takes only one argument, $uid, as in the patch at #566610: blogtitle and realname are incompatible.
Thanks,
Andrew.
Comment | File | Size | Author |
---|---|---|---|
#2 | blogtitle-tokens-0.patch | 1.14 KB | ashtonium |
blogtitle_breadcrumbs.patch | 678 bytes | Andrew Schulman | |
blog_node_breadcrumb.png | 53.44 KB | Andrew Schulman |
Comments
Comment #1
ashtonium CreditAttribution: ashtonium commentedThis incorrectly affects the breadcrumbs on taxonomy term pages as well. Might be better to simply expose the blog title value to the Token module. Then a module like Custom Breadcrumbs can correctly override the blog node breadcrumbs and not force it be be directly under Home.
Comment #2
ashtonium CreditAttribution: ashtonium commentedmaybe something like this? this patch adds on token hook implementations for [blogtitle] and [blogtitle-raw] which you can then use anywhere you use tokens, including the Custom Breadcrumbs module.
Comment #3
remi CreditAttribution: remi commentedThank you for your work! The patch files have been committed to version 1.3.
Comment #4
remi CreditAttribution: remi commentedComment #5
Andrew Schulman CreditAttribution: Andrew Schulman commentedSo, what is it exactly that I'm supposed to do now, in order to make the blog title show up correctly in the breadcrumbs? I just upgraded to 6.x-1.3, and OOTB the blog title in breadcrumbs has reverted to "user's blog". Thanks, Andrew.
Comment #6
ashtonium CreditAttribution: ashtonium commented@ remi: looks like the patch may not have been successfully applied... I don't see the code in the 6.x-1.3 version of blogtitle.module. I'm re-opening this issue and updating the version.
About the patch in #2:
It exposes the custom blog title as a Token. In order to make use of that token in the breadcrumbs, it requires the Custom Breadcrumbs and Token modules.
Token doesn't require any configuration and you've most likely already installed it since a number of other modules require it.
Custom Breadcrumbs allows you to define your own breadcrumbs per content type. With the above patch applied, you should have a new option to use tokens like [blogtitle] and [blogtitle-raw] in a custom breadcrumb for Blog entry node-types.
This may or may not be the best way of solving the issue, it just worked best for me so I proposed it as a possible solution. Please test it out and comment or submit a different patch for testing.