View Categories

Filter notification of new topic email text to followers

If you have Board Following enabled, you can filter the text of the email that is sent to followers whenever a new topic is posted on a board.

In your functions.php file, or other suitable place, add the following:

/**
* Filter the notification email text to followers of a board
* @param $message - the original email content
* @param $post - the post object for the new topic
* @board_id - the ID of the board posted on
*/
function your_prefix_notification_email_content( $message, $post, $board_id ) {
// Add your new message content here
$message = 'My new message';
return $message;
}
add_filter( 'ctdb_follower_notification_new_topic_email', 'your_prefix_notification_email_content', 10, 3 );