0
Send email in php?
How to use function mail() in php
2 Answers
+ 5
I agree with Toni Isotalo. Unless you know what you're doing, email ends up being rejected by ISPs, blacklists, the recipients' mail server, or routed to the junk folder.
Using a properly configured SMTP server that is managed by people who understand MX records, SPF, reverse lookup, blacklists, etc will make your life easier.
Also, avoid sending email that gets flagged as spam. Just don't do it. You will struggle sending legitimate email and it's a pain to fix with all the blacklists. And... most SMTP / email services will also ban your account.
+ 3
Dont get used to use it.
Use SMTP server based email library. Try PHPMailer.
Same goes for any language.