WordPress.org

Ready to get started?Download WordPress

Forums

Yoast Breadcrumbs - How can I remove "blog" link? (6 posts)

  1. jheinrichs79
    Member
    Posted 3 years ago #

    I have Yoast Breadcrumbs working. Is there an easy way of removing "BLOG" from the links. Currently it looks like HOME > "BLOG" > Category > Sub-Category > Name of Post.

    The company doesn't want to have a "BLOG" on their website but is in love with the ease of posting items with WordPress.

    Any help would be appreciated :)

    Thanks

  2. spabman
    Member
    Posted 2 years ago #

    What I did was edit the yoast-breadcrumbs.php file. On Line 221 (version 0.8.5) the code show is:

    $output = $homelink.' '.$opt['sep'].' '.bold_or_not($opt['blog']);

    I took out the 'sep' so it looks like this:

    $output = $homelink.' '.$opt[''].' '.bold_or_not($opt['blog']);

    This might not solve the problem with a plugin upgrade by Yoast as it could get written over. We'll put it to test for now.

  3. spabman
    Member
    Posted 2 years ago #

    And of course removing the title 'Blog' from "Anchor text for the Blog:" in the Settings file.

  4. mikepote
    Member
    Posted 2 years ago #

    An alternate way to do it:

    Goto Line 213
    $bloglink = $homelink.' '.$opt['sep'].' <a href="'.get_permalink(get_option('page_for_posts')).'">'.$opt['blog'].'</a>';

    And replace with:

    $bloglink = $homelink;

  5. benfrain
    Member
    Posted 2 years ago #

    @mikepote - thanks for that, exactly what I was after.

  6. webyogi
    Member
    Posted 2 years ago #

    I have duplicate blog on my site e.g You are here: Home » Blog » Blog » would this code remove both of these as i do want one > blog to show?

Topic Closed

This topic has been closed to new replies.

About this Topic