?
Path : /home/admin/public_html/old/mailer/ |
Current File : /home/admin/public_html/old/mailer/sendmail2.php |
<?php ob_start(); require_once('class.phpmailer.php'); $mail = new PHPMailer(); // defaults to using php "mail()" /*$mail->IsSendmail(); // telling the class to use SendMail transport*/ $mail->CharSet = 'UTF-8'; $mail->isSMTP(); $mail->Host='smtp.happytokorea.com'; $mail->Port=25; $mail->SMTPSecure='tls'; $mail->SMTPAuth=true; $mail->Username="info@happytokorea.com"; $mail->Password="ktcc2015"; $mail->AddReplyTo("info@happytokorea.com"); $mail->SetFrom('info@happytokorea.com'); $mail->AddReplyTo("info@happytokorea.com"); echo "<strong>Send To</strong><br>"; $mail->AddAddress("nalin.kiat@gmail.com"); $mail->Subject = "testing"; $mail->MsgHTML(file_get_contents('tempHK.php')); if(!$mail->Send()) { echo "Mailer Error: " . $mail->ErrorInfo; } else { echo "Message sent!"; } ?>