helpful_feedback_email_body_voter

With this filter you can overwrite or manipulate the body of the feedback email for people who voted.

/**
 * @param string $body
 * @return string
 */
add_filter('helpful_feedback_email_body_voter', function(string $body) {
    $body = 'My Body';
    return $body;
});

// Alternate usage:
add_filter('helpful_feedback_email_body_voter', function(string $body) {
    ob_start();
    include 'my-email-template.php';
    $body = ob_get_contents();
    ob_end_clean();

    return $body;
});

Was this post helpful?

Top