WordPress mail sending twice
-
Why wordpress mail sending twice email? Also tried php mail and it sending still twice.
$to = "[email protected]"; $headers = "Reply-To: myemail <[email protected]>\r\n"; $headers .= "Return-Path: myemail <[email protected]>\r\n"; $headers .= "From: [email protected]" ."\r\n"; $headers .= "Organization: myemail.com\r\n"; $headers .= "MIME-Version: 1.0\r\n"; $headers .= "Content-type: text/html; charset=utf-8\r\n"; $headers .= "X-Priority: 3\r\n"; $headers .= "X-Mailer: PHP". phpversion() ."\r\n" ; wp_mail( $to, $subject, $content, $headers ); $admin_email = "[email protected]"; $subject2 = 'Osteti uus parkla pilet!'; $headers2 = "Reply-To: myemail <[email protected]>\r\n"; $headers2 .= "Return-Path: myemail <[email protected]>\r\n"; $headers2 .= "From: [email protected]" ."\r\n"; $headers2 .= "Organization: myemail.com\r\n"; $headers2 .= "MIME-Version: 1.0\r\n"; $headers2 .= "Content-type: text/html; charset=utf-8\r\n"; $headers2 .= "X-Priority: 3\r\n"; $headers2 .= "X-Mailer: PHP". phpversion() ."\r\n" ;
wp_mail($admin_email, $subject2, $content2, $headers2)
Im sending one email for customer if successful payment and second to site admin if there was succesful paymentI dont use any loop. Only fetching single customer email.
Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
- The topic ‘WordPress mail sending twice’ is closed to new replies.