XPertMailer is the new solution for sending e-mails using php. With XPM2 you can send e-mails to inbox ( FromHost() ) and all you need it is a complete documentation for XPM2: https://www.xpertmailer.com/DOCUMENTATION
XPertMailer it is the first php class that can send e-mails via a Relay SMTP Server with autentication and TLS/SSL connection. If you can’t delivery the e-mail using mail() function then you have two options like ‘Relay’ or directly to the ‘Client’. Enjoy ??