[Plugin: Notify on comment] Getting a string of authors' emails (1 post)

  1. nathan12343
    Posted 6 years ago #

    I am using Co Authors Plus to give me more than one author for a post and also Notify on comments to let the Author know when a post has been commented on (not sure why this isn't part of the core).

    The problem is that the code for notify on comments uses

    $user = get_userdata($post->post_author);
    	$to = $user->user_email;

    which only gets the email for the Primary author. There are all sorts of great tags from Co-Authors Plus which I know will return the info that I need, but I have no idea how to get these two lines to work when there is more than one email address.

    If anyone can help me I would be enormously grateful.

Topic Closed

This topic has been closed to new replies.

About this Topic