How to Show Category Description and Title

Category Description

Are you facing issue with category page and don’t know how to show category description and title because some theme does not support this features while working on my theme I face same issue and forget to add category description so we updated all of our themes.

How to Add Description to Category

First you need to add description to category for this go to website or blog wp-admin/ dashboard > Post > category > if already present click on edit category.

category-description

As you can see here, In this Category-Description box. If you fill this box ,however, then you can display it with the help of some really easy code (provided you theme doesn’t already use this function as many don’t) you just need to put this function into your theme where ever you would like  for example:- you can put it on the top of you category-template (Usually category.php or archive.php)

Category Description

 

Add Support for Category Description into Theme

If your theme does not support and display category description, Then no need to worry about it WordPress provides to to customize almost everything for developer and website owner first make sure where you wants to show the description then search for right file mostly Archive.php file contain code for category and other archive pages display now find right place for it. Then just add below code into file.

<?php the_archive_description( '<div class="taxonomy-description">', '</div>' ); ?>

After that your category description will be visible on website you might need to design using css.

.taxonomy-description{
padding:10px;
border:1px solid #ddd;
}

Hope you like this tutorial let us know your views and comments.

Sandy

Sandy

Leave a Reply

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

Name *
Email *