July 6th in PHP Scripts by pbu .

PHP script using mail() vs smtp?

PHP script using mail vs smtp method for emailing

I have often confused about the which method to use for sending mails with a php script. I have used php mail() function in many projects and it is often slow, which is because this function opens sockets everytime you call this function. This doesnt work if you are mass emailing and smtp or sendmail is the way to go.

The best and fast way of sending email is using

- SMTP (faster)
- Sendmail (fast)
- Mail (average)

I would recommend using phpmailer or swiftmailer libraries for rapid development.

Similar Posts:

Share and Enjoy:
  • del.icio.us
  • digg
  • StumbleUpon
  • Technorati
  • DZone
  • Facebook
  • FriendFeed
  • Reddit
  • RSS
  • Twitter

Leave A Comment.