php - How to prevent the email from being considered HTML, when I've already set the headers as "Content-type: text/plain" -


i'm trying figure out why emails considered spam hotmail, i'm using online tool called mail-tester.com.

according it, have 8.4 out of 10, 1 of problems spamassasin detected "message has text/html mime parts", adds "you should include text version of message (text/plain)" , points link spamassasin rule "mime_html_only"

myq uestion is: i'm sending emails using phpmailer. email not blacklisted , happens hotmail.

i'm setting headers text/plain.

i'm putting email content strip_tags() function.

why says i'm sending html?

this i'm using (the whole script quite long, pertinent part sends email. receive email without issues in other email clients, gmail.

require $_server['document_root'].'/phpmailer/phpmailerautoload.php'; $mail = new phpmailer; $mail->issmtp(); $mail->host = 'mail.mysite.online'; $mail->smtpauth = true; $mail->username = 'info@mysite.online'; $mail->port = 25; $mail->charset = 'utf-8'; $headers .= 'content-type: text/plain';   $mensajelimpio = strip_tags($resultado['mailmensaje']); $mail->addaddress($pedidoemail); $mail->subject = $resultado['mailasunto']; $mail->body    = 'estimado/a '.$nombreusuario.',<br>'.$mensajelimpio; 

add $mail->ishtml(false); options


Comments

Popular posts from this blog

ubuntu - PHP script to find files of certain extensions in a directory, returns populated array when run in browser, but empty array when run from terminal -

php - How can i create a user dashboard -

javascript - How to detect toggling of the fullscreen-toolbar in jQuery Mobile? -