Quantcast
Channel: WordPress.org Forums » [WP Mail SMTP by WPForms - The Most Popular SMTP and Email Log Plugin] Support
Viewing all articles
Browse latest Browse all 5019

Sending WooCommerce E-Mail from different mail sender

$
0
0

Replies: 0

Hi!
I have set up the plugin and it’s working. But I need to have several email senders for different WooCommerce Mails, e.g.:
Order received = order@shop.com
Order paid = payment@shop.com
Account confirmation: info@shop.com

I added the following script to my functions.php, but unfortunatly it is not working:
add_filter( ‘woocommerce_email_from_address’, function( $from_email, $wc_email ){
if( $wc_email->id == ‘customer_processing_order’ )
$from_email = ‘order@shop.com’;

return $from_email;
}, 99, 2 );

// WooCommerce Absender Mail Adresse bei Zahlungsbestätigung
add_filter( ‘woocommerce_email_from_address’, function( $from_email, $wc_email ){
if( $wc_email->id == ‘customer_completed_order’ )
$from_email = ‘payment@shop.com’;

return $from_email;
}, 10, 2 );

I would appreciate your help!

Greetings,
Jasmin


Viewing all articles
Browse latest Browse all 5019

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>