Move text description below products on SHOP page on Woocommerce Storefront

201 Views Asked by At

I use Storefront on my Woocommerce website.

I would like to move the description text on Shop page below all the products. I have already done this on the product category pages with this code I found but I do not know how to have the same result for the global Shop catalog page.

add_action('woocommerce_archive_description', 'custom_archive_description', 2 );
function custom_archive_description(){
    if( is_product_category() ) :
        remove_action('woocommerce_archive_description', 'woocommerce_taxonomy_archive_description', 10 );
        add_action( 'woocommerce_after_main_content', 'woocommerce_taxonomy_archive_description', 5 );
    endif;
}

Can you help me please? Thank you in advance.

I do not know how to do this.

1

There are 1 best solutions below

0
Alex On

Here is the code I used if it can help someone else:

    add_action( 'wp', 'tu_move_wc_archive_description' );
function tu_move_wc_archive_description() {
    if ( is_archive() ) {
        remove_action( 'woocommerce_archive_description', 'woocommerce_product_archive_description', 10 );
        add_action( 'woocommerce_after_main_content', 'woocommerce_product_archive_description', 10 );
    }
}