Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- add_filter( 'the_author', 'guest_author_name' );
- add_filter( 'get_the_author_display_name', 'guest_author_name' );
- function guest_author_name( $name ) {
- global $post;
- $author = get_post_meta( $post->ID, 'author', true );
- if ( $author )
- $name = $author;
- return $name;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement