Home > Backend Development > PHP Tutorial > PHP定时刷新当前页面

PHP定时刷新当前页面

不言
Release: 2023-02-28 16:12:02
Original
10942 people have browsed it

PHP中定时刷新页面的功能如何实现!  
1分钟刷新一次页面!  
这一般不用php实现,用客户端的脚本就可以,甚至用html自带的就行。  
html实现:  

<meta http-equiv="refresh" content="60">echo "<META HTTP-EQUIV=REFRESH CONTENT=&#39;60;URL=index.php&#39;>";
Copy after login

php刷新当前页面

echo "<script language=JavaScript> location.replace(location.href);</script>";echo &#39;服务器忙,请<a href="javascript:document.location.reload()">刷新</a>页面,或稍后再试!谢谢!!&#39;;exit;
Copy after login

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