WordPress.org

Ready to get started?Download WordPress

Forums

custom post descriptions (3 posts)

  1. jtancil@yahoo.com
    Member
    Posted 3 years ago #

    Hello,
    I have created a page that uses custom posts: http://www.africanhealthleadership.org/resources/toolkit/

    Each tool (Preparation, Assessment, etc.) is a custom post. On the WP Admin, each tool is a category; each category has a "description" field. I would like to output those descriptions on the Toolkit page. I tried using this and nothing displayed:
    <?php echo category_description( $category ); ?>

    Right now, the descriptions are hard-coded in to the page. The one for preparation begins
    "Preparation tools establish..."

    Thank you for any ideas!
    Jeff

  2. LeoAltair
    Member
    Posted 3 years ago #

    Each tool (Preparation, Assessment, etc.) is a custom post. On the WP Admin, each tool is a category;

    Not clear for me : is it a custom post or a category ?

    If it's a post, you could use editor for the big text (the_content) and excerpt for the description-preview (the_excerpt : check spelling, I never get it right)

    As the big text is just desc + a list, you could even simplier put a "more" separator in you editor and have an automatic exerpt

  3. jtancil@yahoo.com
    Member
    Posted 3 years ago #

    Thanks for the reply. It's a custom post. Like a regular post, custom posts can have categories. Does that clarify?

Topic Closed

This topic has been closed to new replies.

About this Topic