• If you are still using CentOS 7.9, it's time to convert to Alma 8 with the free centos2alma tool by Plesk or Plesk Migrator. Please let us know your experiences or concerns in this thread:
    CentOS2Alma discussion

phpMailer

DiegoAlves

New Pleskian
Guys, my phpmailer began to accuse the following error:
Error: The following From address failed:
He was running smoothly.


code:
<? php}
else {
/ * SEND MAIL


$ msg = "
Name: $ _POST [ipt_nome]
Email: $ _POST [ipt_email]
Message: $ _POST [ipt_mensagem]
";

require ("phpmailer / class.phpmailer.php");
$ mail = new PHPMailer ();
$ mail-> CharSet = "iso-8859-1";
$ mail-> IsSMTP ();
$ mail-> Host = "mail.meudominio.com.br";
$ mail-> SMTPAuth = true;
$ mail-> Username = "[email protected]";
$ mail-> Password = "asdfahDdfa838";
$ mail-> Port = 587;
$ mail-> From = $ _POST ['ipt_email'];
$ mail-> FromName = $ _POST ['ipt_nome'];
$ mail-> AddAddress ('[email protected]', 'Contact');
$ mail-> IsHTML (true);
$ mail-> Subject = 'Website - Contact';
$ mail-> Body = $ msg;
if (! $ mail-> Send ()) {
echo 'Error <h2> send your message </ h2>';
print "Error:". $ mail-> ErrorInfo;

}
else {
echo 'h2> Message sent successfully. </ h2>';

}

unset ($ _POST ['ipt_send']);

}
?>
 
Back
Top