Buenas,
Me estoy peleando con PHPMailer y no lo soluciono. Haga lo que haga me da el siguiente error:
SMTP Error: The following recipients failed:
[email protected]
El código php es este:
Código PHP:
Ver originalinclude ("/class/class.phpmailer.php");
$mailPrto = new PHPMailer(true); //defaults to using php "mail()"; the true param means it will throw exceptions on errors, which we need to catch
try {
$mailPrto->SMTPDebug = true;
$mailPrto->IsSMTP();
$mailPrto->SMTPAuth = true;
$mailPrto->Host = "smtp.xxx.es";
$mailPrto->Port = 25;
$mailPrto->Username = "xxx";
$mailPrto->Password = "xxx";
$mailPrto->From = "xxx";
$mailPrto->AddReplyTo = $correo;
$mailPrto->FromName = $nombre;
$mailPrto->AddAddress(xxx, 'web'); //para
$mailPrto->SetFrom(aaa, 'mensaje'); //de
$mailPrto->CharSet = 'UTF-8';
$mailPrto->Subject = "asunto";
$mailPrto->AltBody = 'bla bla bla'; // texto alternativo
$mailPrto->IsHTML(true); // Activamos el formato HTML
$mailPrto->MsgHTML($message);
$mailPrto->Send();
} catch (phpmailerException $e) {
echo $strMsgFrmErr[$idioma].' '.$e->errorMessage(); //Pretty error messages from PHPMailer
} catch (Exception $e) {
echo $strMsgFrmErr[$idioma].' '.$e->getMessage(); //Boring error messages from anything else!
}
He activado el debug y sale lo siguiente. Entiendo poco, pero al menos tengo claro que la autenticación es correcta.
SMTP -> get_lines(): $data was ""
SMTP -> get_lines(): $str is "220 smtp-03.servidoresdns.net ESMTP Postfix "
SMTP -> get_lines(): $data is "220 smtp-03.servidoresdns.net ESMTP Postfix "
SMTP -> FROM SERVER:220 smtp-03.servidoresdns.net ESMTP Postfix
SMTP -> get_lines(): $data was ""
SMTP -> get_lines(): $str is "250-llsa735-a03.servidoresdns.net "
SMTP -> get_lines(): $data is "250-llsa735-a03.servidoresdns.net "
SMTP -> get_lines(): $data was "250-llsa735-a03.servidoresdns.net "
SMTP -> get_lines(): $str is "250-PIPELINING "
SMTP -> get_lines(): $data is "250-llsa735-a03.servidoresdns.net 250-PIPELINING "
SMTP -> get_lines(): $data was "250-llsa735-a03.servidoresdns.net 250-PIPELINING "
SMTP -> get_lines(): $str is "250-SIZE 51200000 "
SMTP -> get_lines(): $data is "250-llsa735-a03.servidoresdns.net 250-PIPELINING 250-SIZE 51200000 "
SMTP -> get_lines(): $data was "250-llsa735-a03.servidoresdns.net 250-PIPELINING 250-SIZE 51200000 "
SMTP -> get_lines(): $str is "250-ETRN "
SMTP -> get_lines(): $data is "250-llsa735-a03.servidoresdns.net 250-PIPELINING 250-SIZE 51200000 250-ETRN "
SMTP -> get_lines(): $data was "250-llsa735-a03.servidoresdns.net 250-PIPELINING 250-SIZE 51200000 250-ETRN "
SMTP -> get_lines(): $str is "250-STARTTLS "
SMTP -> get_lines(): $data is "250-llsa735-a03.servidoresdns.net 250-PIPELINING 250-SIZE 51200000 250-ETRN 250-STARTTLS "
SMTP -> get_lines(): $data was "250-llsa735-a03.servidoresdns.net 250-PIPELINING 250-SIZE 51200000 250-ETRN 250-STARTTLS "
SMTP -> get_lines(): $str is "250-AUTH PLAIN DIGEST-MD5 CRAM-MD5 LOGIN "
SMTP -> get_lines(): $data is "250-llsa735-a03.servidoresdns.net 250-PIPELINING 250-SIZE 51200000 250-ETRN 250-STARTTLS 250-AUTH PLAIN DIGEST-MD5 CRAM-MD5 LOGIN "
SMTP -> get_lines(): $data was "250-llsa735-a03.servidoresdns.net 250-PIPELINING 250-SIZE 51200000 250-ETRN 250-STARTTLS 250-AUTH PLAIN DIGEST-MD5 CRAM-MD5 LOGIN "
SMTP -> get_lines(): $str is "250-AUTH=PLAIN DIGEST-MD5 CRAM-MD5 LOGIN "
SMTP -> get_lines(): $data is "250-llsa735-a03.servidoresdns.net 250-PIPELINING 250-SIZE 51200000 250-ETRN 250-STARTTLS 250-AUTH PLAIN DIGEST-MD5 CRAM-MD5 LOGIN 250-AUTH=PLAIN DIGEST-MD5 CRAM-MD5 LOGIN "
SMTP -> get_lines(): $data was "250-llsa735-a03.servidoresdns.net 250-PIPELINING 250-SIZE 51200000 250-ETRN 250-STARTTLS 250-AUTH PLAIN DIGEST-MD5 CRAM-MD5 LOGIN 250-AUTH=PLAIN DIGEST-MD5 CRAM-MD5 LOGIN "
SMTP -> get_lines(): $str is "250-ENHANCEDSTATUSCODES "
SMTP -> get_lines(): $data is "250-llsa735-a03.servidoresdns.net 250-PIPELINING 250-SIZE 51200000 250-ETRN 250-STARTTLS 250-AUTH PLAIN DIGEST-MD5 CRAM-MD5 LOGIN 250-AUTH=PLAIN DIGEST-MD5 CRAM-MD5 LOGIN 250-ENHANCEDSTATUSCODES "
SMTP -> get_lines(): $data was "250-llsa735-a03.servidoresdns.net 250-PIPELINING 250-SIZE 51200000 250-ETRN 250-STARTTLS 250-AUTH PLAIN DIGEST-MD5 CRAM-MD5 LOGIN 250-AUTH=PLAIN DIGEST-MD5 CRAM-MD5 LOGIN 250-ENHANCEDSTATUSCODES "
SMTP -> get_lines(): $str is "250 8BITMIME "
SMTP -> get_lines(): $data is "250-llsa735-a03.servidoresdns.net 250-PIPELINING 250-SIZE 51200000 250-ETRN 250-STARTTLS 250-AUTH PLAIN DIGEST-MD5 CRAM-MD5 LOGIN 250-AUTH=PLAIN DIGEST-MD5 CRAM-MD5 LOGIN 250-ENHANCEDSTATUSCODES 250 8BITMIME "
SMTP -> FROM SERVER: 250-llsa735-a03.servidoresdns.net 250-PIPELINING 250-SIZE 51200000 250-ETRN 250-STARTTLS 250-AUTH PLAIN DIGEST-MD5 CRAM-MD5 LOGIN 250-AUTH=PLAIN DIGEST-MD5 CRAM-MD5 LOGIN 250-ENHANCEDSTATUSCODES 250 8BITMIME
SMTP -> get_lines(): $data was ""
SMTP -> get_lines(): $str is "334 VXNlcm5hbWU6 "
SMTP -> get_lines(): $data is "334 VXNlcm5hbWU6 "
SMTP -> get_lines(): $data was ""
SMTP -> get_lines(): $str is "334 UGFzc3dvcmQ6 "
SMTP -> get_lines(): $data is "334 UGFzc3dvcmQ6 "
SMTP -> get_lines(): $data was ""
SMTP -> get_lines(): $str is "235 2.7.0 Authentication successful "
SMTP -> get_lines(): $data is "235 2.7.0 Authentication successful "
SMTP -> get_lines(): $data was ""
SMTP -> get_lines(): $str is "250 2.1.0 Ok "
SMTP -> get_lines(): $data is "250 2.1.0 Ok "
SMTP -> FROM SERVER:250 2.1.0 Ok
SMTP -> get_lines(): $data was ""
SMTP -> get_lines(): $str is "553 5.7.1 : Sender address rejected: not owned by user
[email protected] "
SMTP -> get_lines(): $data is "553 5.7.1 : Sender address rejected: not owned by user
[email protected] "
SMTP -> FROM SERVER:553 5.7.1 : Sender address rejected: not owned by user
[email protected]
SMTP -> ERROR: RCPT not accepted from server: 553 5.7.1 : Sender address rejected: not owned by user
[email protected]
Alguna sugerencia?
Gracias