SMTP Email is not working with OJS

When ever a user register or submit a paper, email is not triggering. We thought mail() is not working so we setup SMTP in file. We have mentioned correct SMTP server. But getting below error in logs and mail is not working:

[02-Apr-2016 05:14:36] ojs2 has produced an error
Message: WARNING: fsockopen() [function.fsockopen]: unable to connect to (Connection refused)
In file: /research/lib/pkp/classes/mail/
At line: 165
Server info:
OS: Linux
PHP Version: 5.3.6
Apache Version: N/A
DB Driver: mysql
DB server version: 5.1.55

Kindly provide your expertise help.

Hi @ijeditor,

Did you use the ssl:// wrapper as part of the hostname? Have a look at this example for gmail:

Note that we can’t help too much in debugging specific configurations; I’m not familiar with Yahoo’s SMTP service.

Alec Smecher
Public Knowledge Project Team

take a look on this link