Err Posted January 26, 2012 Share Posted January 26, 2012 I'm trying to get the time it takes to finish loading a script of mine. I have it in a loop that does the same action over and over again for a set number of times and each loops takes a required amount of time. However the number loops that it has to do increases over time. I'm trying to find a way to get the estimated amount of time for the script to finish. I've looked into data transfer rate, which is alright for connections over the internet but I'm dealing with things server-side. Any idea how I can go about this? Link to comment Share on other sites More sharing options...
JamesB Posted January 26, 2012 Share Posted January 26, 2012 you can check how long the php scripts takes to run with microtime(), at the top of the first file which is ran: $start = microtime(true); and the bottom of that file: $end = microtime(true);echo 'took '..(($end - $start) * 1000)..' milliseconds'; Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.