//setup phpmailer application; please use version => 5.2.9
require('/home/username/public_html/phpmailer/class.PHPMailerAutoload.php');
$mail = new PHPMailer(); //creates an instance of the class
$mail->IsSMTP(); // telling the class to use SMTP--THIS LINE IS REQUIRED BY ABHOST
$mail->Host = "mail.abhost.net"; // sets the SMTP server
$mail->Port = 587; // set the SMTP port for the server
$mail->SMTPSecure == "tls"; // enable TLS security
$mail->SMTPAuth = true; // enable SMTP authentication
$mail->Username = "user@example.com"; // SMTP account username
$mail->Password = "thisisabadpassword"; // SMTP account password
//the following line saves a lot of time finding out where badly formed emails are originating
$mail->AddCustomHeader("X-Sending-script-URL: /YourScriptName.php"); //note: spaces are not allowed before the colon
$mail->SetFrom('no-replies@example.com', 'www.example.com');