CakePHP (CakeMail) を使用して Microsoft Exchange 2010 Server に電子メールを送信するために、いくつかの構成オプションを試してきました。これは私の現在の構成です:
public $default = array(
'transport' => 'Smtp',
'from' => array('email@example.com' => 'Me'),
'host' => 'smtp.ex3.secureserver.net',
'port' => 587,
'timeout' => 30,
'username' => 'verifiedUserName',
'password' => 'verifiedPassword',
'client' => null,
'log' => true,
'delivery' => 'smtp'
);
そして、これは私のテスト関数です:
public function test_email() {
App::uses('CakeEmail', 'Network/Email');
$email = new CakeEmail();
$email->config('default');
debug($email->config());
$result = $email->template('checkout')
->from('email@example.com')
->emailFormat('text')
->to('another@example.com')
->subject('TEST EMAIL ')
->send();
}
私は取得しています
SMTP Error: 504 5.7.4 Unrecognized authentication type
ホストを「ssl://smtp.ex3.secureserver.net」または「tls://smtp.ex3.secureserver.net」に変更すると、
Unable to connect to SMTP server.
サーバーは TLS を使用するように構成されています。
何か案は ?