Forums

Breadcrumb NavXT
[resolved] Omitting Specific Words from Breadcrumb Trail (2 posts)

  1. seofanatic
    Member
    Posted 5 months ago #

    I am trying to figure out how to omit certain words from the anchor text in my breadcrumb trail. Each breadcrumb anchor text is displayed based on the name of the page or post being displayed. I want to hack the plugin so certain text is removed from one of the page breadcrumbs even though it is in the title of that specific page.

    For example, my current breadcrumbs are being displayed like this:

    Home > NFL Football Teams > San Francisco 49ers

    I want the breadcrumbs to be displayed like this:

    Home > NFL > San Francisco 49ers

    In the above example, the text "Football Teams" is removed from the parent page in the breadcrumb trail.

    Can this be done by hacking the plugin php code or with javascript?

    http://wordpress.org/extend/plugins/breadcrumb-navxt/

  2. mtekk
    Member
    Posted 5 months ago #

    I have to strongly caution against modifying the files distributed with Breadcrumb NavXT. Doing so will make upgrading to newer versions more difficult.

    You could throw some javascript together to strip out Football Teams from "NFL Football Teams", probably not the most elegant way of doing it, however.

    The way I'd go about it is to use http://plugins.trac.wordpress.org/export/482629/breadcrumb-navxt/branches/extensions/breadcrumb_navxt_cust_paged_title.php as a guide to traverse the breadcrumb trail before it is assembled and modify the title. I may be able to provide example code, just may be a week or so.

Reply

You must log in to post.

About this Plugin

About this Topic