I have been able to successfully send mail with PHPMailer tutorial code like this...
isSMTP();
//Enable SMTP debugging
$mail->SMTPAuth = true;
$mail->SMTPDebug = 2;
$mail->Host = 'ssl://smtp.yandex.ru';
$mail->Port = 465;
$mail->Username = 'EDITED';
$mail->Password = 'EDITED';
//Set the hostname of the mail server
//Set the SMTP port number - likely to be 25, 465 or 587
//Whether to use SMTP authentication
//Username to use for SMTP authentication
//Password to use for SMTP authentication
//Set who the message is to be sent from
$mail->setFrom('EDITED', 'Daniel');
//Set an alternative reply-to address
$mail->addAddress('EDITED', 'Daniel');
//Set who the message is to be sent to
//Set the subject line
$mail->Subject = 'PHPMailer SMTP test';
$mail->Body = 'This is a plain-text message body';
//send the message, check for errors
if (!$mail->send()) {
echo 'Mailer Error: ' . $mail->ErrorInfo;
} else {
echo 'Message sent!';
}
?>
Unfortunately, none of the contact forms work that I upload to my site... with or without recaptcha (Recaptcha displays and is solved correctly).
https://withdaniel.ru (Message in footer)
or
https://withdaniel.ru/contact-2.html (It turns grey and nothing happens. Just an example. Not going to use)
I'm guessing form.php needs to be updated to work with newer PHPMailer?
