I've used PHPMailer on several projects but now I'm stuck. It gives me the error:
SMTP Error: Could not connect to SMTP host.
I've tried sending email from Thunderbird and it works ! But not through PHPMailer ... Here are the settings from Thunderbird:
Server name: mail.exampleserver.com
Port: 587
Username: user@exampleserver.com
Secure Authentication: No
Connection Security: STARTTLS
Ben PHPMailer kullanılmış ve onlar benim son projesi sunucu ile bu karşılaştırıldı ettik:
Server name: mail.exampleserver2.com
Port: 465
Username: user@exampleserver2.com
Secure Authentication: No
Connection Security: SSL/TLS
Benim php kodu:
$mail = new PHPMailer();
$mail->IsSMTP(); // send via SMTP
$mail->Host = SMTP_HOST; // SMTP servers
$mail->Port = SMTP_PORT; // SMTP servers
$mail->SMTPAuth = true; // turn on SMTP authentication
$mail->Username = SMTP_USER; // SMTP username
$mail->Password = SMTP_PASSWORD; // SMTP password
$mail->From = MAIL_SYSTEM;
$mail->FromName = MAIL_SYSTEM_NAME;
$mail->AddAddress($aSecuredGetRequest['email']);
$mail->IsHTML(true); // send as HTML
Ben yanlış nerede?