Maximum run time 30 seconds

Help me please! I retrieved the listing on my system from the database. But until this error appears: it has a thousand listings:

Fatal error: maximum run time exceeded by 30 seconds

This code is from my htaccess

php_value max_execution_time 3000 php_value upload_max_filesize 512M php_value post_max_size 512M php_value memory_limit 256M php_value set_time_limit 0 

How can i solve this? I use PHP and MYSQL.

+21
php mysql .htaccess
Apr 09 '13 at 13:59 on
source share
5 answers

you can increase the maximum runtime as follows:

 ini_set('max_execution_time', 0); 

otherwise edit htaccess

 php_value max_execution_time 0 
+33
Apr 09 '13 at 14:02
source share

Add this to the top of your php file

 ini_set("max_execution_time", 0); 
+6
Apr 09 '13 at 14:02
source share

If to run php using the command line interface (CLI) use:

 ini_set('max_execution_time', -1); 

else run:

 ini_set('max_execution_time', 0); 
+2
Dec 04 '13 at 14:27
source share

The same error we encounter on wordpress

we made changes to .htaccess, but that didn’t work.

Then we created one php.ini file marked with this code and uploaded to the root directory

 max_execution_time = 60 

and he fixed the problem.

+2
Mar 03 '17 at 1:55
source share

At the top of the file, set the timeout:

 set_time_limit(0); 
+1
Apr 09 '13 at 14:18
source share



All Articles