View Full Version : help with the "page creation time"
01-26-2003, 06:15 AM
im trying to figureout what method is faster while i make the scripts.
to do that i need to know how long it took to complete the script.
can anyone tell me how to do that?
thx in advanced.
01-26-2003, 04:29 PM
I've got a thing that times how long a page takes to load, from request to completion; it's a broad knife but it should show you if x feature makes a big difference - http://www.brothercake.com/scripts/loadtimer.php
01-26-2003, 10:01 PM
here it is :D
//script by Afrim S. <firstname.lastname@example.org>
//loading time function
$time_start = getmicrotime();
list($usec, $sec) = explode(" ",microtime());
return ((float)$usec + (float)$sec);
//end of loading time function
//YOUR CODE GOES HERE
//final code for Loading time. DO NOT DELETE
$time_end = getmicrotime();
$time = $time_end - $time_start;
echo "Page generated in ".number_format($time,4)." seconds";
brothercake, thanks for that link.
Powered by vBulletin® Version 4.2.2 Copyright © 2017 vBulletin Solutions, Inc. All rights reserved.