about using mail function

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
mekya
Forum Newbie
Posts: 9
Joined: Mon Mar 27, 2006 3:10 am

about using mail function

Post by mekya »

hi,
As you know, php built-in mail function take mail addresses separated by comma as TO parameter,

my question is: what is the performance difference in php or in view of postfix when sending mail to a list of mail adresses individually in a for loop or concating all mail adresses separated by comma and then sending in a one mail() function call?
User avatar
s.dot
Tranquility In Moderation
Posts: 5001
Joined: Sun Feb 06, 2005 7:18 pm
Location: Indiana

Post by s.dot »

I've never used a comma to send to multiple addresses.

I do know that sending emails in a loop is abusing what *could* be one connection to the mail server. d11wtq's Swift Mailer at http://www.swiftmailer.org is a fantastic library for addressing issues such as this.
Set Search Time - A google chrome extension. When you search only results from the past year (or set time period) are displayed. Helps tremendously when using new technologies to avoid outdated results.
mekya
Forum Newbie
Posts: 9
Joined: Mon Mar 27, 2006 3:10 am

Post by mekya »

thank you...
Post Reply