Last active
March 3, 2016 21:21
-
-
Save jameskoster/6761140 to your computer and use it in GitHub Desktop.
Remove breadcrumbs on WooCommerce pages in WooThemes
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
add_action( 'init', 'jk_remove_woo_wc_breadcrumbs' ); | |
function jk_remove_woo_wc_breadcrumbs() { | |
if ( is_woocommerce() || is_cart() || is_checkout() ) { | |
remove_action( 'woo_main_before', 'woo_display_breadcrumbs', 10 ); | |
} | |
} |
Could override on all pages using an empty child theme functions.php statement:
function woocommerce_breadcrumb() {}
Or perhaps override by copying plugins/woocommerce/templates/global/breadcrumb.php to childtheme/woocommerce/global/breadcrumb.php and add an if statement to just remove on WooCommerce pages ( is_woocommerce() || is_cart() || is_checkout() )
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
This is ineffective on the Storefront theme with the ProShop child theme.