Jump to content

Will my PC effected if i set max_execution_time


manalnor

Recommended Posts

Hello friends,

 

i'm using localserver which is AppServ

and i want to run php function in closed loop and may takes hours and hours

 

when i've tried, i've got that error

 

Fatal error: Maximum execution time of 30 seconds exceeded

 

 

what if i changed in PHP.INI setting for example

 

max_execution_time = 99999999999999999;

 

does it will effect on my pc or anything wrong or internet ..ect

This doesn't seem right.  Can you explain what you're trying to do, maybe we can suggest a better approach.  If you must, you can temporarily set the max_execution_time with ini_set.

 

  Quote
does it will effect on my pc or anything wrong or internet ..ect

It may shut down the entire internet so be careful.

oh thanks for the informations.

 

here is the main idea

 

for ($i=1;$i>=1;$i++)
{
$id = rand(100, 100000);
$sql= "insert into mytable set id='$id'";
} 

it means it will insert into database table an random number from btween 100 to 100000 but after 30 seconds it gives me the error

 

Fatal error: Maximum execution time of 30 seconds exceeded

 

so any idea ? i'm afraid if i set the MET > 30 Seconds will effects on my pc processor or internet router  :shrug:

  Quote

  Quote
does it will effect on my pc or anything wrong or internet ..ect

It may shut down the entire internet so be careful.

 

lol

 

I'm pretty sure that loop will never stop, but I may be wrong... if $i >= 1..it will always be greater than 1 if you keep increasing it

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.