AnsweredAssumed Answered

SugarCRM 5.0: SMTP Error when sending email: Could not connect to SMTP host.

Question asked by Sultan Sultan on Jun 21, 2014
Warning: fsockopen() [function.fsockopen]: unable to connect to ssl://smtp.gmail.com:465 (Unable to find the socket transport "ssl" - did you forget to enable it when you configured PHP?) in C:\xampp\htdocs\include\phpmailer\class.smtp.php on line 104 Error emailing:SMTP Error: Could not connect to SMTP host.

The above mention error I get every time when I tried to send the email from Sugar.
I am using SugarCRM 5.0 Community Edition on XAMPP 1.7(Apache 2.0 and PHP 5).

I tried to find out solutions online and tried these things:
>Port 465, 587, 993
>Removed comment from   extension=php_openssl.dll in php.ini
>Upgraded Apache 2.2 to 2.4
>Disabled Firewall

And my current email settings are:
(In Admin>>Email Settings: Configure)
"From" Name: *  =  SugarCRM
"From" Address: *  =  myemail@gmail.com
Save Outbound Raw Emails *  =  No
Mail Transfer Agent:  =  SMTP
SMTP Server: *  =  smtp.gmail.com
 SMTP Port: *  =  465
 Use SMTP Authentication?  =  (Checked)
Enable SMTP over SSL  =  (Checked)
SMTP Username: *  =  myemail@gmail.com
SMTP Password: *  =  my gmail password

And in Email Module >> Settings >> Mail Accounts, settings are:
Name: *  =  My Name
From Name:  =  Administrator
From Address: *  =  myemail@gmail.com
User Name: *   =  myemail@gmail.com
Password: *   =  my gmail password
Mail Server Address: *  =  smtp.gmail.com
Mail Server Protocol: *   =  IMAP
Mail Server Port: *  =  143 (I saved 465 here but when I came again in these settings, I saw 143)
Use SSL:  =  (Checked)

And in  Outgoing Mail Server: * settings are:
SMTP Server *  =  smtp.gmail.com
SMTP Port *  =  465
Use SSL when connecting:  =  (Checked)
Use SMTP Authentication?  =  (Checked)


I tried everything which I found online but nothing works.

Outcomes