zoukankan
html css js c++ java
ASP禁止刷新当前页
方法1:
<
%
Dim
SplitReflashPage
Dim
DoReflashPage
dim
shuaxin_time
DoReflashPage
=
true
shuaxin_time
=
10
ReflashTime
=
Now
()
if
(
not
isnull
(session(
"
ReflashTime
"
)))
and
cint
(shuaxin_time)
>
0
and
DoReflashPage
then
if
DateDiff
(
"
s
"
,session(
"
ReflashTime
"
),
Now
())
<
cint
(shuaxin_time)
then
response.write
"
<META http-equiv=Content-Type content=text/html; charset=gb2312><meta HTTP-EQUIV=REFRESH CONTENT=3>本页面起用了防刷新机制,请不要在<b><font color=ff0000>
"
&
shuaxin_time
&
"
</font></b>秒内连续刷新本页面<BR>正在打开页面,请稍候……
"
response.
end
else
session(
"
ReflashTime
"
)
=
Now
()
end
if
elseif
isnull
(session(
"
ReflashTime
"
))
and
cint
(shuaxin_time)
>
0
and
DoReflashPage
then
Session(
"
ReflashTime
"
)
=
Now
()
end
if
randomize
timer
regjm
=
int
(
rnd
*
8998
)
+
1000
%
>
方法2:
<
%
Dim
URL
If
DateDiff
(
"
s
"
,Request.Cookies(
"
oesun
"
)(
"
vitistime
"
),
Now
())
<
2
Then
URL
=
Request.ServerVariables(
"
Http_REFERER
"
)
Response.Write(
"
<meta http-equiv=""refresh"" content=""2;URL=
"
&
URL
&
"
"">
"
)
Response.Write(
"
防刷新,两秒后自动跳转
"
)
Response.
End
End
IF
Response.Cookies(
"
oesun
"
)(
"
vitistime
"
)
=
Now
()
%
>
青苹果Web应用商店
https://webapp.taobao.com/
PHP/ASP.NET/ASP/UCHOME/DISCUZ! X系列网站开发,详细需求联系
QQ:8511978
查看全文
相关阅读:
[BZOJ-1007&洛谷P3194][HNOI2008]水平可见直线--【半平面交(单调栈)】
[BZOJ-1006&洛谷P3196][HNOI2008]神奇的国度--【图的染色-最大势MCS算法】
[BZOJ-1005&洛谷P2624][HNOI2008]明明的烦恼-【Purfer序列】py+java
[BZOJ1211 & 洛谷P2290] [HNOI2004]树的计数-【Purfer序列】py+Java
【BZOJ-1004&洛谷P1446】[HNOI2008]Cards-置换群(burnside引理|DP)
POJ-2409 Let it Bead 【置换群-Polya定理】
Dijkstra--POJ 2502 Subway(求出所有路径再求最短路径)
二分--LIGHTOJ 1088查找区间(水题)
二分--1043
二分---LIGHTOJ 1062
原文地址:https://www.cnblogs.com/Dicky/p/131082.html
最新文章
1139 First Contact
1140 Look-and-say Sequence
1141 PAT Ranking of Institutions
1142 Maximal Clique
1143 Lowest Common Ancestor
1144 The Missing Number
1145 Hashing
PHP、 Ruby、Python、Java、C++、C、Objective C——编程语言之禅
ITester软件测试小栈,点击领取你的能量值!
PHP、 Ruby、Python、Java、C++、C、Objective C——编程语言之禅
热门文章
APP测试之Monkey压力测试(一)
嘘,我已经瞒着开发解锁APP日志文件抓取及分析啦!
速看,APP测试之ADB最全指南!
给我两小时,我能写很长长长长长长的APP测试用例!
无法拒绝APP测试的理由,如果你还不知道,是我的错!
请允许我用2019年11种主流编程语言,祝祖国70华诞快乐!
POJ-2452-Sticks Problem(二分+RMQ)
POJ-1330&HDU-2586 最近公共祖先(不带权+带权)树剖式写法求LCA
HDU-3183 A Magic Lamp--贪心+暴力数组移动
BZOJ-1008&洛谷P3197--越狱【HNOI2008】推公式
Copyright © 2011-2022 走看看