0

Why php always give me that error ? I changed php.ini values to :

max_execution_time = 99999 ;
max_input_time = 99999;
max_input_nesting_level = 64; 
memory_limit = 256M; 
max_input_vars = 10000;

i have created .htaccess file where i put :

php_value max_execution_time 9999

i have located php.ini 50 times to be sure i am at right location.

I have set :

set_time_limit(9999);

at the begining of my php script.

I have restarted MAMP 50 times, even laptop.

If i use phpinfo(); at the begining of my php script i can see both values (local and master) are set to 99999

I changed phpmyadmin conf located in MAMP\bin\phpMyAdmin\libraries\config.default.php to :

// maximum execution time in seconds (0 for no limit)
    $cfg['ExecTimeLimit'] = 0;

But nothing works. Still getting error. Any help is appreciated.

Peter Štieber
  • 43
  • 2
  • 10
  • 1
    When you use `phpinfo();` are you sure that these changes are reflected in phpmyadmin? phpmyadmin uses another php.ini that does not concern the default apache php.ini (at least on some systems). – OptimusCrime Oct 18 '17 at 13:29
  • After googeling "phpmyadmin max execution time exceeded" i found: https://stackoverflow.com/questions/1263680/maximum-execution-time-in-phpmyadmin – Roland Starke Oct 18 '17 at 13:30
  • see edited question – Peter Štieber Oct 18 '17 at 13:32

1 Answers1

0

First of all, are you sure you need 300 seconds of execution time? It seems rather impractical to me that a call would take 5 minutes to return an answer. I would recommend looking through your code to make sure there's no infinite loops or the likes anywhere.

Anyways, if your code is working as intended, you should check your php.ini file for another occurrence of max_execution_time which overrides yours, because the default should be at 30 seconds, and not at 300, as far as i know.

Also, you can try adding ini_set('max_execution_time', -1) at the beginning of your code. This drops the maximum execution time entirely.

Keshpeth
  • 121
  • 9