A question about max_execution_time
| From: | Eric Butera | Date: | Mon, 10 Apr 2006 18:30:31 +0000 |
| Subject: | A question about max_execution_time | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-233681@lists.php.net to get a copy of this message | ||
Dear List,
I have been working with a PHP script that curls a file from another
server. This works fine on my local machine, but not on our live server.
The script takes about 400 seconds to execute completely. I was under the
impression that my call to set_time_limit(900); was helping. Well, I took
that line out and nothing changed locally or on the server. In fact I even
tried this little test:
<?php
// header include for my config (to get Util)
error_reporting(E_ALL);
echo '<br>max execution time: '. ini_get('max_execution_time');
sleep(40);
echo "<br>done!";
echo "<br><br>Script Executed Time: ". Util::displayMicroTime(
$_SCRIPT_START_TIME, Util::getMicroTime() );
die('<br>'.__FILE__.__LINE__);
?>
Outputs:
max execution time: 30
done!
Script Executed Time: 40.01
/Users/eric/Sites/test/member_get_update.php26
Now why did this work? Shouldn't the script have timed out after 30
seconds?
Thanks in advance!
Eric