Categories
WooCommerce

WooCommerce Product Category Page Customization

Display the product category description after the products instead of before:

add_action( 'woocommerce_archive_description', 'condless_custom_archive_description', 2 );
function condless_custom_archive_description() {
        if( is_product_category() ) {
                remove_action( 'woocommerce_archive_description', 'woocommerce_taxonomy_archive_description' );
                add_action( 'woocommerce_after_main_content', 'woocommerce_taxonomy_archive_description', 5 );
        }
}

Display the category description only on hover (CSS):

.term-description {
	display: none;
}

.woocommerce-products-header__title:hover + .term-description {
	display: block;
	border-style: ridge;
}

Leave a Reply

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