Automattic / Co-Authors-Plus

Multiple bylines and Guest Authors for WordPress
https://wordpress.org/plugins/co-authors-plus/
GNU General Public License v2.0
291 stars 204 forks source link

How to display co-authors within RSS feed <dc:creator> tags? #736

Closed AJB99 closed 3 years ago

AJB99 commented 4 years ago

Currently all the tags in my RSS feed are the WP User that originally created the post, and not the co-author assigned as the author for display.

How do I get the co-author to display within the tags of my RSS feed?

I've already attempted the following, but it doesn't work:

function db_coauthors_in_rss( $the_author ) {

    if ( !is_feed() || !function_exists( 'coauthors') ){
        return $the_author;
    }
    else{
        return coauthors( null, null, null, null, false );
    }

}
add_filter( 'the_author', 'db_coauthors_in_rss');
rebeccahum commented 4 years ago

@AJB99 This should work as expected, it just may be that your feed is cached and you will need to publish a new post or update a current one to see those changes.

nielslange commented 3 years ago

Closing due to inactivity.