Setting amount of time to pass when sending emails in a loop
Posted
by Obay
on Stack Overflow
See other posts from Stack Overflow
or by Obay
Published on 2010-04-25T12:14:58Z
Indexed on
2010/04/25
12:23 UTC
Read the original article
Hit count: 324
Forgive me for this noob question, but is there such a setting that sets a certain amount of time (e.g. milli/seconds) that has to pass in between sending emails through a script? How is that setting called and where do I change that setting?
I'll give an example: I used to have a PHP script that sends emails like so:
for ($i=0; $i<count($emails); $i++) {
mail($email[$i],'test','test');
}
It turned out that not all emails were sent successfully because the script ran so fast that there was not enough time in between sending emails that was required by the server.
Did I make sense?
© Stack Overflow or respective owner