Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Change the word Products in the WooCommerce breadcrumb trail
add_filter( 'woo_breadcrumbs_trail', 'woo_custom_filter_breadcrumbs_trail', 10 );
function woo_custom_filter_breadcrumbs_trail ( $trail ) {
foreach ( $trail as $k => $v ) {
if ( strtolower( strip_tags( $v ) ) == 'products' ) {
$trail[$k] = 'Photos';
break;
}
}
return $trail;
} // End woo_custom_filter_breadcrumbs_trail()
@cameracctv247
Copy link

cameracctv247 commented Aug 2, 2019

thank for this code, great!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment