Re: Speed issues
| From: | The.Rock | Date: | Thu, 15 May 2003 15:56:13 +0000 |
| Subject: | Re: Speed issues | ||
| References: | 1 | Groups: | php.windows |
| Request: | Send a blank email to php-windows+get-19953@lists.php.net to get a copy of this message | ||
I'm on the same platform as you and sometimes when I refresh it takes a
couple of seconds to create the page. So I built this funtion to see how
long it really takes to create. I believe it is IIS serving up the webpage
that makes it takes so long. Put the start time at the beginning of the
script and the end time at the bottom (footer??)..Here ya go:
function getmicrotime() {
$bits = explode(" ", microtime());
return $bits[0] + $bits[1];
}
//this gets the start time it takes to run a script
$time_start = getmicrotime();
// lets get the ending time
$time_end = getmicrotime();
$total=$time_end-$time_start;
$total_format= number_format($total,4);
print "Created page in $total_format sec(s)";
"Charles P. Killmer" <charlesk@netgaintechnology.com> wrote in message
news:B141BE87473AA64FB24370C43CEA54BD29FC31@ngexbe1.my-netgain.com...
PHP 4.3.1 CGI mode
IIS 5.0
Windows 2000 Server
Every now and then I get scripts that take > 30 seconds to complete.
The same script usually takes < 1 second. Could a client on a VERY slow
connection be slowing this process down?
In a request process who handles queueing the data until the client can
download all of it? IIS or PHP or both?
Charles Killmer