I have the regular wordpress code to display category description:
<?php echo category_description( $category_id ); ?>
But how can i display Woocommerce category description?
@@
After one of the comment suggestion i added:
<?php
if ( have_posts() ) {
while ( have_posts() ) {
the_post();
global $post, $product; $categ = $product->get_categories(); $term = get_term_by ( 'name' , strip_tags($categ), 'product_cat' ); echo $term->description;
} // end while
} // end if
?>
Still, not work.
Edit for Last answer:
the_archive_description()
worked for my purposes when other (more complicated) solutions would not.Optional before and after string parameters can be added if needed.
You can display the product category description –
use this code –
The main answer for some reason displayed more than one description for me.
The answer below solved this for anyone with the same issue:
https://stackoverflow.com/a/19266706/2703913