首页 小组 问答 话题 好文 素材 用户 唠叨 我的社区

[分享]php 获取代码执行时间

风轻yLv.1种子选手
2024-09-11 14:24:23
0
43

$stime=microtime(true); 

中间是代码运行逻辑

$etime=microtime(true);//获取程序执行结束的时间
$total=$etime-$stime;   //计算差值
echo "<br />当前页面执行时间为:{$total} 秒";

风轻y
风轻y

41 天前

签名 :   43       0
评论
站长交流