Add category description if it exists
Add the category description to your category templates, but only if it exists. This also wraps the description in div tags.
1 2 3 4 5 |
<?php $category_description = category_description(); if ( ! empty( $category_description ) ) echo apply_filters( 'category_archive_meta', '<div class="description">' . $category_description . '</div>' ); ?> |
Thanks, this was just what I needed
Lovely stuff, thank you 🙂