Viewing 1 replies (of 1 total)
  • Plugin Author YITHEMES

    (@yithemes)

    Hi ekornmeyer,

    Just checked on my local installantion, and breadcrumb for brands archive are something like this

    Home / Brands / <Brand>

    Here an example.

    If you want to add shop page in this breadcrumb, maybe you can use the filter provided by woocommerce, adding something like this

    if( ! function_exists( 'add_shop_to_breadcrumb' ) ) {
    	function add_shop_to_breadcrumb( $crumbs ) {
    		if ( ! function_exists( 'YITH_WCBR' ) ) {
    			return $crumbs;
    		}
    
    		if ( is_tax( YITH_WCBR::$brands_taxonomy ) ) {
    			$home = $crumbs[0];
    			$tail = array_slice( $crumbs, 1 );
    			$shop = array(
    				__( 'Shop', 'yith-wcbr' ),
    				get_the_permalink( wc_get_page_id( 'shop' ) )
    			);
    
    			$crumbs = array_merge(
    				array( $home ),
    				array( $shop ),
    				$tail
    			);
    		}
    
    		return $crumbs;
    	}
    }
    add_filter( 'woocommerce_get_breadcrumb', 'add_shop_to_breadcrumb', 10, 1 );

    to functions.php file of your theme

    Let me know if this helps
    Have a nice day! ??

Viewing 1 replies (of 1 total)
  • The topic ‘Brand Archive Breadcrumbs not working??’ is closed to new replies.