Posts Tagged by microtime

PHP Tutorial: Timing Your Code

Sometimes you need to know how long a script takes to run, or perhaps just a part of it. Sometimes you can think of two ways to do something and want to know which is the fastest. That's where the microtime() function comes in mighty handy. $start = microtime(true); //code //to //execute $end = microtime(true);…