2

Could you please tell me how to increase the execution time in php in godaddy web hosting. I have tried .user.ini file in website folder below is my code

max_execution_time=5000

Could you please explain how to achieve this in godaddy.

Sri
  • 631
  • 2
  • 7
  • 21

3 Answers3

1

In .htaccess

<IfModule mod_php5.c>
php_value max_execution_time 5000
</IfModule>

OR place this at the top of your PHP script

ini_set('max_execution_time', 5000);
Farhan
  • 1,453
  • 2
  • 15
  • 20
  • You are saying to add this in the header.php file or any othe file. – Sri Jan 01 '16 at 13:50
  • if you will add this in header.php than this will be available on all pages where header.php is included, also if you add this in .htaccess than again this will effect on all web – Farhan Jan 01 '16 at 13:51
  • I have included in the .htaccess only but still the 504 gateway error shows any other way to solve in the godaddy – Sri Jan 01 '16 at 13:53
  • you can read this article also http://www.bala-krishna.com/how-to-change-php-setting-using-php-ini-in-godaddy-shared-hosting/ – Farhan Jan 01 '16 at 13:53
0
ini_set('max_execution_time',0);
Caleb Kleveter
  • 11,170
  • 8
  • 62
  • 92
0

Usually the php.ini is located in the home/ of your hosting file manager. You can edit the same form there or in case you don't have access to this file you can use the .htaccess file located in the landing directory of your particular website.