Home > Backend Development > PHP Tutorial > PHP implements web page execution timing function

PHP implements web page execution timing function

WBOY
Release: 2016-08-08 09:30:49
Original
1548 people have browsed it

microtime(): Get millisecond-level UNIX timestamp

<?php
$t=microtime();
/*
你要执行的代码
*/
echo "哦啦啦啦啦啦啦啦";
$t=microtime()-$t;
echo "<br>本次代码执行用了$t毫秒.";
?>
Copy after login

The above introduces the implementation of web page execution timing function in PHP, including aspects of content. I hope it will be helpful to friends who are interested in PHP tutorials.

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template