Hey, I need a programmer to code me a simple script that sends out a mail to ~1500 users. The emails are all saved in a database, so the script would have to get the emails from there. The coder would have to decide what amount of mails the script will send each minute, considering spam.. Send me a quote for this job in a PM.
Try this: <?php $sql=mysql_connect("server","user","password"); $db=mysql_select_db("database",$sql); $adds=mysql_query("SELECT emails FROM table"); while($emails=mysql_fetch_array($add)) { mail($emails['email'],"Subject","Message"); sleep(5); // send a mail every 5 seconds } mysql_close($sql); ?>
IF you want to use this, don't forget to set the time limit to 0. set_time_limit(0); PHP: 0 = unlimited. But yes, I agree with EAD, use phplist instead.