<?php


//require("class.phpmailer.php");
require '/home/silentvalley/public_html/SMTP/class.phpmailer.php';
require '/home/silentvalley/public_html/SMTP/class.smtp.php';

$mail = new PHPMailer(true);

$mail->IsSMTP();                                      // Set mailer to use SMTP
//$mail->Host = "mail.silentvalleyresorts.com";                 // Specify main and backup server
$mail->Host = 'localhost';                 // Specify main and backup server
//$mail->Host = "Give IP Address";                 // If the above does not work.
$mail->Port = 25;                                    // Set the SMTP port
$mail->SMTPAuth = true;                               // Enable SMTP authentication
$mail->Username = "lookup@greenplanetresorts.com";                // SMTP username
$mail->Password = "Z1hIi7O@z";                  // SMTP password
//$mail->SMTPSecure = "ssl";                            // Enable encryption, 'ssl' also accepted

$mail->From = 'lookup@greenplanetresorts.com';
$mail->FromName = 'From name';
$mail->AddAddress('otsolutions.mlr@gmail.com');  // Add a recipient

$mail->IsHTML(true);                                  // Set email format to HTML

$mail->Subject = 'Here is the subject';
$mail->Body    = 'This is the HTML message body <strong>in bold!</strong>';
$mail->AltBody = 'This is the body in plain text for non-HTML mail clients';

if(!$mail->Send()) {
	print_r($mail);
   echo 'Message could not be sent.';
   echo 'Mailer Error: ' . $mail->ErrorInfo;
   exit;
}

echo 'Message has been sent';
exit(0);?>
