Edit woocommerce_product_archive_description using hook

I want to customize the category description in woocommerce. I see that the hook is woocommerce_product_archive_description, but I’m not able to get the category description,I will get the product description instead. Did I miss something in my code?

remove_action( ‘woocommerce_archive_description’,’woocommerce_taxonomy_archive_description’, 10 );
remove_action( ‘woocommerce_archive_description’,’woocommerce_product_archive_description’, 10 );

function theme_woocommerce_product_archive_description()
{
?>
<div class=”col-sm-12 col-md-12 col-lg-12″>
<?php the_excerpt(); // this will give me the wrong result ?>
</div>
<?php
}
add_action( ‘woocommerce_archive_description’,’theme_woocommerce_product_archive_description’, 10 );

Read more here:: Edit woocommerce_product_archive_description using hook

Leave a Reply

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