最新下载
热门教程
- 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9
- 10
大灰狼的ASP工具箱――防盗链、判断星期几
时间:2022-07-02 23:42:04 编辑:袖梨 来源:一聚教程网
防盗链
<%
http=Request.ServerVariables("HTTP_REFERER")
http2=Cstr(Request.ServerVariables("SERVER_NAME"))
if mid(http,8,len(http2))<>http2 then
response.write "本站禁止从外部站点下载!"
else
response.redirect "download.doc" 'download.doc为下载文件名
end if
%>
-------------------------------------------------------
判断星期几
<%
yue=month(date())
nian=year(date())
thismon=nian&"-"&yue&"-1"
nextmon=dateadd("m",1,thismon)
tiancount=datediff("d",thismon,nextmon) '本月的天数
wek= Weekday(date())
select case wek
case 1
response.write "周日"
case 2
response.write "周一"
case 3
response.write "周二"
case 4
response.write "周三"
case 5
response.write "周四"
case 6
response.write "周五"
case 7
response.write "周六"
end select
yue=month(date())
nian=year(date())
thismon=nian&"-"&yue&"-1"
nextmon=dateadd("m",1,thismon)
tiancount=datediff("d",thismon,nextmon) '本月的天数
dim wek,wekday
wek= Weekday(date())
select case wek
case 1
wekday= "周日"
case 2
wekday= "周一"
case 3
wekday= "周二"
case 4
wekday= "周三"
case 5
wekday= "周四"
case 6
wekday= "周五"
case 7
wekday= "周六"
end select
'response.write "本月共"&tiancount&"天,今天是"&wekday&"
%>
相关文章
- 《彩色点点战争》推图常用三大主c玩法详解 01-23
- 《燕云十六声》池鱼林木任务攻略 01-23
- 《大连地铁e出行》查看行程记录方法 01-23
- 《明日方舟》2025春节限定干员余角色介绍 01-23
- 《崩坏:星穹铁道》万敌光锥搭配攻略 01-23
- 《燕云十六声》一药千金任务攻略 01-23