hi all,
I want to send email using SMTP Authentication with PHPMailer,
I searched more and more but I can't find anything of my problem....
///////////////////////////////////////////////////////////////////
include_once('class.phpmailer.php');
include("class.smtp.php"); // optional, gets called from within
class.phpmailer.php if not already loaded
$mail = new PHPMailer();
$mail->IsSMTP();
$mail->Host = "mail.xxxxxxxxxx.com"; // sets GMAIL as the SMTP
server
$mail->Port = 80;
$mail->Username = "[email protected]"; // SMTP username
$mail->Password = "xxxxx"; // SMTP password
$mail->From = "[email protected]";
$mail->FromName = "First Last";
$mail->Subject = "PHPMailer Test Subject via smtp";
$mail->AltBody = "To view the message, please use an HTML compatible
email viewer!"; // optional, comment out and test
$mail->MsgHTML("hiiii");
$mail->AddAddress("[email protected]", "John Doe");
//$mail->AddAttachment("images/phpmailer.gif"); // attachment
if(!$mail->Send()) {
echo "Mailer Error: " . $mail->ErrorInfo;
} else {
echo "Message sent!";
}
////////////////////////////////////////////////
result is nothing, no error but didn't send
then I remove Username & password, but didn't work!...
thanks,
shahrzad khorrami