hi i need some advice on making a bulk emailer script more robust. what i'm currently doing: -using mysql_fetcharray() to loop through an array of query results -for each iteration of the loop, get an email address from the current row in the result set, and use it with the mail() function to send out an individual email to that email address, then echo out a confirmation in HTML so that the user will know that an email has been sent -this is repeated for each email address found in the result set problem with this is: with large result sets (some of my result sets come up with a few thousand email addresses), users have to wait a long time for the confirmation messages to print out to their browser, sometimes it seems that not all the messages go through what i've tried: -using mysql_fetcharray() to loop through an array of query results -for each iteration of the loop, get an email address from the current row in the result set, and append it to a long strong called $bcc -then i plug the value of $bcc into the mail() command, which is issued only once at the end of the loop -this method seems to work better, does not take as long, HTML confirmation messages get printed faster since mail() function is only called once at the end of the loop, only one email is sent (with a long BCC field), so it doesn't bog the server down so much problem with this method is: with large result sets (some of my result sets come up with a few thousand email addresses), the BCC field is so large that it is too large for the mail server to send out has anyone done a bulk emailer script to send out mass emails? if you have any advice re: methodology, i'd like to hear it. thanks redmond -- Redmond Militante Software Engineer / Medill School of Journalism FreeBSD 5.2.1-RELEASE-p10 #0: Wed Sep 29 17:17:49 CDT 2004 i386 2:30PM up 9 days, 3:27, 3 users, load averages: 0.00, 0.01, 0.00
Attachment:
pgpYhKnCGjK0a.pgp
Description: PGP signature