I need a set of mail headers to attach to my mail()
function in PHP. I send emails with HTML in them, and sometimes services like Yahoo Mail block them. Therefo
$headers = "From: testsite < mail@testsite.com >\n";
$headers .= "Cc: testsite < mail@testsite.com >\n";
$headers .= "X-Sender: testsite < mail@testsite.com >\n";
$headers .= 'X-Mailer: PHP/' . phpversion();
$headers .= "X-Priority: 1\n"; // Urgent message!
$headers .= "Return-Path: mail@testsite.com\n"; // Return path for errors
$headers .= "MIME-Version: 1.0\r\n";
$headers .= "Content-Type: text/html; charset=iso-8859-1\n";