"Web/PHP"에 해당되는 글 1건

  1. 2012.12.06 PHP 수행 시간 측정

PHP 수행 시간 측정

2012. 12. 6. 13:52

<?php
function get_time() {
    list($usec, $sec) = explode(" ", microtime());
    return ((float)$usec + (float)$sec);
}
$start = get_time();
/*
수행할 내용
*/
$end = get_time();
$time = $end - $start;
echo '<br/>'.$time.'초 걸림';
?>

,