Search
Close this search box.

How to set custom breadcrumb delimiter in WooCommerce

To set a custom breadcrumb delimiter in WooCommerce using the functions.php file, you can use the woocommerce_breadcrumb_defaults filter hook. This hook allows you to modify the default settings for the WooCommerce breadcrumb function.

Here is an example of how you can use this hook to set a custom breadcrumb delimiter in WooCommerce:

// Set custom breadcrumb delimiter in WooCommerce
// More snippets at wpunplugged.com 

function custom_breadcrumb_delimiter( $defaults ) {
    $defaults['delimiter'] = '>'; // Set the delimiter to ">"
    return $defaults;
}
add_filter( 'woocommerce_breadcrumb_defaults', 'custom_breadcrumb_delimiter' );

In this example, we are setting the delimiter to “>”. You can use any string or character as the delimiter.

Share this post

You might also like...

Backup

Jetpack for WordPress Review

Jetpack for WordPress is an amazing plugin that offers a wide range of features to help make your WordPress website more secure, efficient and user-friendly.

Read More »

Comment

Your email address will not be published. Required fields are marked *