Email SMTP (port release)

Asked

Viewed 192 times

0

I’m trying to send an email by phpmailer, but it’s always a mistake. So I went to look at some examples of git, but not even the examples are going. I need to release port 25 or 465 to be able to send the SMTP email?

  • Which error gives? Connection error? Enable debug to see what happens. $mail->Smtpdebug = true; I usually use port 587 for my work with Phpmailer. $mail->Port = 587;

  • I need to change my door in shampoo to 587 to be able to do this?

  • It gives the following error: Error in e-mailSMTP connect() failed. https://github.com/PHPMailer/PHPMailer/wiki/Troubleshooting&#Xa

  • If it simply gives SMTP connect() failed, it is because in some reason the connection has been refused. Sometimes it is not port. Make sure your server does not ask for SMTP authentication, login, password... did you put the Debug I informed? Usually it has more data about the error.

  • Which SMTP server are you trying to connect to?? if it’s gmail you need to also configure gmail SMTPSecure for ssl. If it is another, you need to see what is needed for configuration. Any missing information may fail. Here’s an example of Phpmailer with gmail: https://www.gn10.com.br/blog/dicas/envie-emails-php-smtp-gmail-google-apps/ Also call SMTPDebug = 1; 1, to display error messages. So you can have more details of what is happening.

No answers

Browser other questions tagged

You are not signed in. Login or sign up in order to post.