Home » Php » Increase PHP Script Execution Time

Increase PHP Script Execution Time

Posted by: admin April 23, 2020 Leave a comment


I want to send hundreds of emails using PHP. To increase the execution time, I used ini_set(‘max_execution_time’, 10); but after sending just 30 emails the browser shows me a blank page and does not send all of the emails.

I also changed the limit to 300, 600 ..

How to&Answers:

Try set_time_limit(0); at the top of your script.

set_time_limit sets the maximum execution time in seconds. If set to zero, no time limit is imposed (see PHP manual).