WordPress.org

Ready to get started?Download WordPress

Forums

[Plugin: Custom Taxonomies] display description for category (2 posts)

  1. nbierma
    Member
    Posted 4 years ago #

    Sorry for probably missing something obvious, but what's the key to getting the description to display for a term in the taxonomy? For a category it's

    <?php if (is_category('Category A')) { ?>
    <p>This is the text to describe category A</p>

    What's the equivalent for taxonomies created via this plugin?

    http://wordpress.org/extend/plugins/custom-taxonomies/

  2. nbierma
    Member
    Posted 4 years ago #

    OK, I found it here -- http://bit.ly/9ldLdc :

    <?php $term = get_term_by( 'slug', get_query_var( 'term' ), get_query_var( 'taxonomy' ) ); echo $term->name; ?>
    <?php echo term_description( '', get_query_var( 'taxonomy' ) ); ?>

Topic Closed

This topic has been closed to new replies.

About this Topic