I was looking for the same type of information a few weeks ago, I eventually
found what I was looking for in the phpbb system.
Here is the code that they used.
//put right after your first opening PHP tag
$mtime = microtime(); // page creation timers
$mtime = explode(" ",$mtime);
$mtime = $mtime[1] + $mtime[0];
$starttime = $mtime;
unset ($mtime);
// put right before end of your page
$mtime = microtime();
$mtime = explode(" ",$mtime);
$mtime = $mtime[1] + $mtime[0];
$endtime = $mtime;
$totaltime = ($endtime - $starttime);
printf("<center>Page created in %f seconds.</center>", $totaltime);
-----Original Message-----
From: John Fishworld [mailto:[EMAIL PROTECTED]]
Sent: Friday, February 22, 2002 1:23 PM
To: William Lovaton; [EMAIL PROTECTED]
Subject: Re: [PHP] Miliseconds with PHP4
how out of interest ?
> Hello there,
>
> I want to know the execution time of some scripts I made, I'm using the
> difference of seconds (time() function) between the start and the end of
> the script.
>
> But, I would like to get a greater precision... so, I was wondering if
> there is a chance to get miliseconds.
>
> TIA
>
> William
>
>
> _________________________________________________________
> Do You Yahoo!?
> Get your free @yahoo.com address at http://mail.yahoo.com
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php