I have a .php page that loops through a database and sends an email to person. There are over 200 emails sent out. I initially had the problem where the scrip would time out (usually because invalid email addresses take more time), so I set set_time_limit
I'm sorry, I just realized my original message got cut off. I do have ignore_user_abort() and set_time_limit(0) at the top of the code. The problem appears to be that something causes the page to refresh as many as ten times, resulting in everyone getting the same email ten times.
The page itself is the result of a post, but at the end of the post script it does a header so if the client refreshes their browser the posting script isn't run again.
It looks to me like there's still some timeout or retry that's causing the php to automatically reload.
I'm really wondering if there's any additional codeing techniques in php that people are using to programatically deliver many (>200) emails.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.