mercredi 7 octobre 2015

Php Laravel 5.1- Connection could not be established with host smtp.gmail.com [Connection refused #111]

this is .env file, and everything works on localhost:

APP_ENV=local
APP_DEBUG=true
APP_KEY=******

DB_HOST=127.0.0.1
DB_DATABASE=dbname
DB_USERNAME=dbuser
DB_PASSWORD=*****

CACHE_DRIVER=file
SESSION_DRIVER=file
QUEUE_DRIVER=sync

MAIL_DRIVER=smtp
MAIL_HOST=smtp.gmail.com
MAIL_PORT=587
MAIL_NAME=My app
MAIL_USERNAME=mail@private.com
MAIL_PASSWORD=*****
MAIL_ENCRYPTION=tls 

But trying to send a mail online (i have GoDaddy as hosting) i get this error:

Swift_TransportException in StreamBuffer.php line 265:
Connection could not be established with host smtp.gmail.com [Connection refused #111]

I'm searching for a solution but can't still find the cause.



via Chebli Mohamed

Aucun commentaire:

Enregistrer un commentaire