1
<?php
    /**
     * woocommerce_before_main_content hook
     *
     * @hooked woocommerce_output_content_wrapper - 10 (outputs opening divs for the content)
     * @hooked woocommerce_breadcrumb - 20
     */
    //do_action( 'woocommerce_before_main_content' );
?>

For now, I'm just commenting it out to disable before main content and after main content.
Is it possible to do it without modifying the plugin files?

<?php
    /**
     * woocommerce_after_main_content hook
     *
     * @hooked woocommerce_output_content_wrapper_end - 10 (outputs closing divs for the content)
     */
    //do_action( 'woocommerce_after_main_content' );
?>

1 Answer 1

3
remove_action('woocommerce_before_main_content', 'woocommerce_output_content_wrapper', 10,0);

remove_action('woocommerce_before_main_content', 'woocommerce_breadcrumb', 20,0);

remove_action('woocommerce_after_main_content', 'woocommerce_output_content_wrapper_end', 10,0);

I hope it works for you =)

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.