# Sending email without mail()

**URL:** <https://forum.kirupa.com/t/sending-email-without-mail/294090>\
**Category:** Uncategorized\
**Created:** [August 8, 2009, 4:08am UTC](https://forum.kirupa.com/t/sending-email-without-mail/294090 "2009-08-08T04:08:15Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![arundracula](https://avatars.discourse-cdn.com/v4/letter/a/5f8ce5/32.png) [@arundracula](https://forum.kirupa.com/u/arundracula)\
**Post date:** [August 8, 2009, 4:08am UTC](https://forum.kirupa.com/t/sending-email-without-mail/294090/1 "2009-08-08T04:08:15Z")

</div>

I have a site hosted at byethost. They says sendmail supported. The mail() function returns true. But the mail is not received.  
So I used the phpmailer to use gmail SMTP. It is working. In the received mail my gmail id is shown. I changed the AddReplyTo and SetFrom in Phpmailer. But it is displayed as if I send it from my gmail account.

This hosting service has a webmail service pop3.  
How to use that service in php to send mail so that [mail@mydomain.com](mailto:mail@mydomain.com) is displayed in the received mail?  
Please help. Thanks in advance.
