fuel / email

Fuel PHP Framework - Fuel v1.x Email library
60 stars 38 forks source link

Email package does not support STARTTLS server #55

Closed kenjis closed 10 years ago

kenjis commented 10 years ago

So we can't send email to, for example, smtp.live.com.

See details: http://fuelphp.com/forums/discussion/13018/tls-support-for-smtp#Item_5

See also: http://www.php.net/manual/ja/transports.inet.php#113244

WanWizard commented 10 years ago

I don't have a server that supports this handy, so I haven't tested it. Can you?

kenjis commented 10 years ago

@WanWizard Thanks!

I could send email via smtp.live.com.

'smtp'  => array(
            'host'      => 'smtp.live.com',
            'port'      => 587,
            'username'  => '__username__',
            'password'  => '__password__',
            'timeout'   => 5,
            'starttls'  => true,
        ),
WanWizard commented 10 years ago

cool, thanks for the feedback!

bernhardh commented 10 years ago

With the changed mentioned abouve the email packages (smtp) stops working for me.

I have the following config:

return array( 'defaults' => array( 'driver' => 'smtp', 'smtp' => array( 'host' => 'ssl://smtp.gmail.com', 'port' => 465, 'username' => 'XXXXX@gmail.com', 'password' => 'XXXXXX', 'timeout' => 5, ), 'newline' => "\r\n", ), );

which worked before the https://github.com/fuel/email/commit/1b265ab240f8e7ce3f0cef3acdd32686e84ca071 changes. Now I get:

"Fuel\Core\PhpErrorException [ Warning ]: stream_socket_client(): php_network_getaddresses: getaddrinfo failed: Der angegebene Host ist unbekannt."

...which means the the given host is unknown. I had to switch back to the old code.

WanWizard commented 10 years ago

Can't test this fix here, can you?

bernhardh commented 10 years ago

Thank you, its now working again!