Co-Authors Plus
[resolved] Showing custom fields for Guest Authors (2 posts)

  1. krosenberg
    Posted 3 years ago #

    I am using the User-Titles plugin to display an author's title (ex: Associate Sports Editor) for a newspaper website. However, I'd like to give titles to Guest Authors as well. I added a custom field, guest-title, to the post type Guest Author, but how should I show this custom field value in single.php ?

    I would typically use get_post_meta($post_id, $key, $single); but I do not know how to get the $post_id of the Guest Author associated with the current post.

    Any ideas?


  2. Daniel Bachhuber
    Hand Built
    Plugin Author

    Posted 3 years ago #

    If you're using get_coauthors() to get the co-authors, then $author->ID will be the post ID

Topic Closed

This topic has been closed to new replies.

About this Plugin

  • Co-Authors Plus
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic