Last active
August 29, 2015 14:21
-
-
Save lmartins/634943a137667d63ac35 to your computer and use it in GitHub Desktop.
Notifies additional emails when a order is completed. By default this only notifies the Customer.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
* ---------------------------------------------------------------------------- | |
* ADDS ANOTHER RECIPIENT TO COMPLETE ORDER EMAIL NOTIFICATION | |
* Permite que as notificações enviadas para o cliente sejam copiadas | |
* em BCC para outros destinatarios | |
* ---------------------------------------------------------------------------- | |
*/ | |
add_filter( 'woocommerce_email_headers', 'mycustom_headers_filter_function', 10, 3); | |
function mycustom_headers_filter_function( $headers, $email_id, $object ) { | |
if ($email_id == 'customer_completed_order') { | |
$headers .= 'BCC: [email protected], [email protected]' . "\r\n"; | |
} | |
return $headers; | |
} | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment