[英]CodeIgniter / Gmail SMTP timeout on IIS
我正在嘗試使用codeigniter發送簡單的電子郵件:
$email_config = Array(
'protocol' => 'smtp',
'smtp_host' => 'ssl://smtp.googlemail.com',
'smtp_port' => 465,
'smtp_user' => 'xxx',
'smtp_pass' => 'xxx'
);
$this->load->library('email', $email_config);
$this->email->from('no-reply@mysite.com', 'Admin');
$this->email->to($email_address);
$this->email->subject('Test Subject');
$this->email->message('Test Message');
$this->email->send();
但這只是超時。 我在php.ini中沒有注釋extension = php_openssl.dll,但是我猜想還有其他安裝問題。 我在IIS7上運行。
您是否嘗試過檢查服務器的出站互聯網連接,以確保一切正常? 另外,我還要檢查防火牆設置。
在我看來,這似乎不像CI或PHP的問題,我通過gmail發送的配置看起來像這樣,所以在這里一切都很好。
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.