Skip to content
← Back to the journal
Tips / Recommendations 1 min read

Woocommerce product category description under products

In order to display the description of the Woocommerce product category at the bottom of the page – under the products, you need to add the following code to the functions.php file of the theme:

remove_action( 'woocommerce_archive_description', 'woocommerce_taxonomy_archive_description', 10 );
add_action( 'woocommerce_after_shop_loop', 'woocommerce_taxonomy_archive_description', 100 );
function woocommerce_taxonomy_archive_description() {
    if ( is_tax( array( 'product_cat', 'product_tag' ) ) && get_query_var( 'paged' ) == 0 ) {
        $description = wpautop( do_shortcode( term_description() ) );
        if ( $description ) {
            echo '<div class="term-description">' . $description . '</div>';
        }
    }
}

Leave a Reply

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

14 + nine =

From insight to action

Need a clear digital solution for your business?

Discuss a project ↗