• Resolved kuminov

    (@kuminov)


    Hi all. Please help, I can’t display the category description on the product category page. I am using the latest version of woocommerce and avada retail template.

Viewing 1 replies (of 1 total)
  • WebDesk Solution

    (@webdesksolution)

    Hello @kuminov

    You can display the category description in two ways.

    1. Modify or edit the category or template file by creating the custom shortcode to pull the dynamic category description. You can use the following code to create a custom shortcode.
    2. Place the below code in to direct category or template file.
    <?php
    		global $post;
    		$args  = array(
    			'taxonomy' => 'product_category'
    		);
    		$terms = wp_get_post_terms($post->ID, 'product_category', $args);
    		$count = count($terms);
    		if ($count > 0) {
    			foreach ($terms as $term) {
    				echo $term->description;
    			}
    		}
    		?>

    After creating a short code, you can put it on a particular listing page to show a category description.

Viewing 1 replies (of 1 total)
  • The topic ‘category description woocommerce’ is closed to new replies.