Public Ticket #2962514

Change converstation email recipient

Closed
Comments
5 Tickets 2
Ryan started the conversation 5 years ago on January 20, 2022 at 5:10pm

We'd like to have the new conversation notification go to a specific recipient and not go to the administrator at all (who is our developer and not involved in day-to-day ops)


I found this code from another ticket, but how do we exclude the current WP admin, not just add an additional email recipient?


add_filter('b2bking_recipient_new_message', 'change_recipient',10,2);
function change_recipient($recipient, $conversation){    $second_admin = '[email protected]';    $recipient = $recipient.','.$second_admin;    return $recipient;
}

2,762
KingsPlugins replied 5 years ago on January 20, 2022 at 5:12pm

Hi Ryan,

In this case you can replace that snippet with this one:

add_filter('b2bking_recipient_new_message', 'change_recipient',10,2);
function change_recipient($recipient, $conversation){   
    $recipient = '[email protected]';  
    return $recipient;
}

You'd need to replace [email protected] with the address you want your emails to go to.

1

Sign In