I am using jswmtp and sending emails successfully to the accounts within the same domain (e.g. myserver.com). However, my emails are not reaching to the accounts on different domains (e.g. gmail.com or yahoo.com). Is there anything that I am missing? Below is my code:

jwsmtp::mailer mail("somebody@gmail.com",
                         "me@myserver.com",
                         "subject",
                         "message",
                         "mail.myserver.com",
                         jwsmtp::mailer::SMTP_PORT,
                         false);

mail.send();