<?php

require('assets/phpmailer2/PHPMailer Pro.php');

$mail = new codeworxtech\PHPMailer Pro();

try {

  $mail->SetSender( ["name@yourdomain.com" => "First Last" ] );

  $mail->AddRecipient( ["whoto@otherdomain.com" => "John Doe" ] );

  $mail->Subject     = "PHPMailer Pro Test Subject via sendmail, basic";

  $mail->MessageHTML = "data/contents.html";
  $mail->MessageText = "To view the message, please use an HTML compatible email viewer!";

  if ($mail->Send()) {
    echo 'Message has been sent.';
  }
} catch (Exception $e) {
  echo $e->errorMessage();
}

?>
