• Resolved Ian Sackofwits

    (@plantprogrammer)


    I’m having issues with removing the related products in the single product view.

    I used this
    remove_action( 'woocommerce_after_single_product_summary', 'woocommerce_output_related_products', 20 );

    and it is not working with the Hestia theme.

    The Hestia theme has some weird stuff that is possibly prohibiting this code from working:

    private function manage_related_products() {
    		$hooks = array(
    			'add'    => array(
    				array( 'woocommerce_after_single_product', 'woocommerce_output_related_products', 20 ),
    			),
    			'remove' => array(
    				array( 'woocommerce_after_single_product_summary', 'woocommerce_output_related_products', 20 ),
    			),
    		);

    From https://themes.svn.wordpress.org/hestia/3.0.1/inc/modules/woo_enhancements/class-hestia-woocommerce-manager.php

    Hestia recommends this, but this doesn’t work:
    https://docs.themeisle.com/article/833-how-to-remove-related-products-from-hestia

    If I remove array( 'woocommerce_after_single_product', 'woocommerce_output_related_products', 20 ),
    in the preceeding code, the recommended code works, so I don’t know what’s going on.

    • This topic was modified 3 years, 11 months ago by Ian Sackofwits. Reason: Clarification
Viewing 1 replies (of 1 total)
  • Plugin Support RK a11n

    (@riaanknoetze)

    Hi there,

    It looks like Hestia is customising hooks through a private function which means the regular override methods wouldn’t work. Given this, we’d recommend getting in touch with the developers of that theme directly for more support on this.

    If you’re wondering, their support team can be reached at the following link: https://wordpress.org/support/theme/hestia/

Viewing 1 replies (of 1 total)
  • The topic ‘Issue with Removing Related Products with Hestia Theme’ is closed to new replies.