Home Forums WoodMart support forum Blog breadcrumbs structure for posts and categories

Blog breadcrumbs structure for posts and categories

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #705879

    granule.petshop
    Participant

    Hello,
    I am using the default breadcrumbs provided by the WoodMart theme and I would like to adjust their structure for blog content so that it follows a more standard and user-friendly hierarchy.

    Single blog post:

    Current breadcrumb:
    Home / {category}

    Desired breadcrumb:
    Home / Blog / {category} / Post title

    The current breadcrumb skips the Blog page and goes directly from Home to the category. I would like the Blog page to be included as part of the navigation path, and also the post title at the end.

    Blog category page:

    Current breadcrumb:
    Home / Archive for category “ {category}”

    Desired breadcrumb:
    Home / Blog / {category}

    Instead of the generic archive label, I would like the breadcrumb to show the category name and also include the Blog page between Home and the category.

    Could you please advise if there is a recommended way within WoodMart (settings or theme structure) to achieve this behavior for both single posts and blog category pages?

    Thank you in advance.
    Dejan

    #705919

    Hello,

    WoodMart does not have the option to modify the breadcrumbs, unfortunately. There are two kinds of breadcrumbs in our theme: one comes from the WooCommerce plugin and one from WoodMart. If you want to customize one of our theme’s one, you need to edit the file: inc/template-tags.php.

    For the breadcrumbs changes, you can also try to use the Yoast SEO plugin and it’s breadcrumb option:
    https://yoast.com/features/breadcrumbs/

    Best Regards,

    #705929

    granule.petshop
    Participant

    Hello,

    Thank you for your previous clarification regarding blog breadcrumbs in WoodMart.

    Since the Builder Breadcrumbs element does not currently expose hooks for adjusting the blog breadcrumb hierarchy, I implemented a small customization in the functions.php file of a child theme and would like to confirm whether this approach is technically acceptable or if there is a more supported alternative.

    Because the forum does not allow posting code directly, I documented the full workaround here for reference:
    https://github.com/granulepetshop/woodmart-blog-breadcrumbs-workaround

    The customization works as follows:
    • It targets the nav.wd-breadcrumbs element rendered by the WoodMart Builder Breadcrumbs block after page load
    • It inserts the Blog (Posts page) link immediately after Home on blog category and single post pages
    • It appends the post title at the end on single blog posts
    • It includes a simple guard to prevent duplicate insertion
    • It does not modify any WoodMart template files and does not affect WooCommerce breadcrumbs

    My questions are:
    1. Is targeting the rendered Builder Breadcrumbs output in this way considered safe from a theme-update perspective?
    2. Is there any internal hook, filter, or recommended template override for adjusting the breadcrumb hierarchy of the Builder Breadcrumbs element that is not publicly documented?
    3. Would you consider this type of customization acceptable until an official option is available?

    Thank you for your time and guidance.

    Best regards,
    Dejan

Viewing 3 posts - 1 through 3 (of 3 total)