Tagged: 

Viewing 8 posts - 1 through 8 (of 8 total)
  • Author
    Posts
  • #1324785

    Hello, I have two issues with the breadcrumbs of my website’s posts:

    1. The correct breadcrumbs should be: Home > News > Postname. However, the breadcrumbs showing up are: Home > Postname > News > Postname
    2. In addition, “News” should link to my News page (/news). Instead, it links to /category/news.

    I hope you can help!

    Best,

    Albert

    #1324876

    Hey forestrygy,

    Thank you for the inquiry.

    The breadcrumb works correctly in the demo.

    // https://kriesi.at/themes/enfold/2014/04/28/new-electric-cars-are-getting-really-fast/

    Did you use the avf_breadcrumb_trail filter in the functions.php file or modify anything in the theme? We were not able to check the theme options because the account above is not an admin.

    Best regards,
    Ismael

    #1324878

    Hi Ismael,

    I didn’t modify anything in the functions.php.

    I have created an admin account for you. See details attached.

    Thank you,

    Albert

    #1325354

    Hi,

    Thank you for the info.

    We have set the News page as the default blog page in the Enfold > Theme Options panel, which removes the duplicated post title in the breadcrumb but the first category (News) is now included in the breadcrumb trail, so it looks duplicated (Home/News/News/Post Name). You may need to replace the name of the page or use a different category.

    If that is not option, we could use the avf_breadcrumb_trail filter in the functions.php file to remove the category from the breadcrumb.

    
    function ava_remove_element_from_bctrail( $trail, $args ) {
    	if ( is_single() ) {
                    unset ($trail[2]);
    	}
    	return $trail;
    }
    add_filter( 'avia_breadcrumbs_trail', 'ava_remove_element_from_bctrail', 50, 2 );
    

    Best regards,
    Ismael

    #1325411

    Hi Ismael,

    Changing the name of the page is not an option. So, as you suggest, we should use the avf_breadcrumb_trail filter.

    However, I don’t understand why the breadcrumbs are working like that. Is this some kind of error of the theme? Maybe something to look into it in future Enfold updates.

    Thank you,

    Albert

    #1325511

    Hi,

    Thank you for the update.

    However, I don’t understand why the breadcrumbs are working like that.

    It is not an error and the trail is not actually duplicated. It looks like it but it is not. It just so happens that the category and the page in the site have the same name, which is “News”. To remove the first category or the page from the trail, you have to use the filter above.

    Best regards,
    Ismael

    #1325718

    Hi Ismael,

    Thank you, I understand what you mean. All clear. For now, I will leave it as it is.

    Best,

    Albert

    #1325793

    Hi,

    Thanks for the update. Please let us know if you should need any further help on the topic or if we can close it.

    Best regards,
    Rikard

Viewing 8 posts - 1 through 8 (of 8 total)
  • You must be logged in to reply to this topic.