Home > php教程 > php手册 > PHP执行进度百分比代码

PHP执行进度百分比代码

WBOY
Release: 2016-06-13 11:33:23
Original
1069 people have browsed it

 

session_start();
$zs=21;//设置任务总数
if(!isset($_SESSION['num']))
$_SESSION['num']=$zs;//赋予session变量值
$jd=$_SESSION['num']--;//进度值
echo $jd;//显示进度值
echo "<br />";
echo 100-round($jd/$zs*100)."%";//显示完成进度百分比
?>
Copy after login

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 Recommendations
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template