Feb
18
2010

PHP Calculating script execution time


<?php
$start = (float) array_sum(explode(' ',microtime()));

// put you code that wanted to render at here

$end = (float) array_sum(explode(' ',microtime()));

echo "Processing : ". sprintf("%.4f", ($end-$start))." seconds";
?>

Leave a comment

Get Adobe Flash playerPlugin by wpburn.com wordpress themes