1
votes

I want to send email with laravel and I use mailtrap for this when I tested it in local host this work correctly but in sharing host it shows me this error:

Connection could not be established with host smtp.mailtrap.io [Connection timed out #110]

this is my .env file:

MAIL_DRIVER=smtp

MAIL_HOST=smtp.mailtrap.io

MAIL_PORT=2525

MAIL_USERNAME=194f4****98d84

MAIL_PASSWORD=e76fc****f79e7

MAIL_ENCRYPTION=null

when I changed DRIVER value from smtp to sendmail it shows me this error:

"proc_open() has been disabled for security reasons"

1

1 Answers

-1
votes

Outbound mails could be blocked by your hosting provider. As an example, DigitalOcean blocks the out going emails, for security and spam reasons, and to get it running, you must contact the support team.
I would suggest doing the same with your hosting provider.