PHPMailer goes to spam -
i have problem phpmailer. messages go spam on o2 , hotmail. on other servers works well. here code:
require_once('class.phpmailer.php'); require_once('class.smtp.php'); $mail = new phpmailer(); $mail->from = "abc@mydomain.pl"; $mail->fromname = "xyz"; $mail->addreplyto('abc@mydomain.pl', 'xyz'); $mail->charset = 'utf-8'; $mail->host = "mail.mydomain.pl"; $mail->mailer = "smtp"; $mail->smtpauth = true; $mail->username = "abc@mydomain.pl"; $mail->password = "password"; $mail->port = 25; $mail->subject = "subject"; $mail->body = "message"; $mail->addaddress ('xxx@yyy.pl','user'); $mail->send(); can help?
apart possibility server may blacklisted reason, common cause emails landing in spam servers encountered from-address , server's name not match.
consider from-address someone@mydomain.com sent server cheapwebhosting.com, recipient mail server sees discrepancy , consider spam message.
so, should check message headers of test email if happening here (or if notice else looks fishy)
Comments
Post a Comment