Is there way to add additional recipients to woocommerce invoice mail. I have tried to use 'woocommerce_email_headers' hook, but it's not working:
add_filter( 'woocommerce_email_headers', 'mycustom_headers_filter_function', 10, 2);
function mycustom_headers_filter_function($headers, $object) {
$headers = array();
$headers[] = 'Bcc: My Name <[email protected]>';
$headers[] = 'Content-Type: text/html';
return $headers;
}
Any advice?
You can expand the function to include the order as well:
add_filter( 'woocommerce_email_headers', 'woo_cc_emails', 10, 3 );
function woo_cc_emails( $headers, $status, $object ) {
return 'Bcc: [email protected]' . "\r\n";
}
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With