PHP GoDaddy maximum execution time not working

会有一股神秘感。 提交于 2019-12-04 11:21:06

Same problem with 000webhost and bluehost and ProISP, any PHP process running for more than 120 seconds will be terminated, regardless of settings, to prevent the server from overloading, and you must ask a engineer (that actually know what the problem is) for your account/script to get an exemption from this security feature (good luck. Only ProISP actually gave me an exemption for this, for 1 specific php script..) - or you could buy a VPS (ex, ramnode.com ) , or use a webhost that doesn't have this limitation (like syse.no ) , or use a webhost that might be willing to give you an exemption (like proisp.no )

GoDaddy support staff are retarded. why? header( "refresh:30; url=http://my-site.net" ); this will make YOUR BROWSER redirect and has nothing to do with php execution time, and they were unable to find the real cause of the problem, and the real problem has nothing to do with your cpu usage.

This post enabled me to increase my PHP limit.

Key information:

  1. Open an SFTP connection to your GoDaddy hosting account

  2. In the same directory as wp-config.php, create a .user.ini file.

Note the leading .

  1. In this .user.ini file add max_execution_time = 180

This will increase the GoDaddy max_execution_time to 3 minutes.

Add this to at the top of your php script:

set_time_limit(600);
//or set_time_limit(0); unlimited time
ignore_user_abort(1);

Place this at the top of your PHP script

ini_set('max_execution_time', 300); //300 seconds = 5 minutes

if it works then then run

whereis php

Check the output folder location and go this location php.ini file . check max_input_time=?

Godaddy do not allow to update server configuration by default. Even though you find path og php.ini you will not have access to edit via SSH/FTP client as per their policy.

Solution : The only solution which I found was Call to Godaddy support. Once they allow permission you will be able to find editable field in following path for PHP variables.

Path : Home > Software > PHP Version > Switch to PHP Options

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!