首页 | 心情日记 | 建站心得 | 编程技术 | 大盘分析 | 股市信息 | 学习园地 | 电脑技巧 | 物流外贸 | 另类其它 | 站长推荐 | 给我留言 | 相册

用户登陆
用户:
密码:
 
不保存保存一天
保存一月保存一年

站点日历
73 2024 - 4 48
 123456
78910111213
14151617181920
21222324252627
282930


站点统计

最新评论

日志搜索

 标题   内容


asp中利用数组实现数据库记录的批量录入方法 用Asp隐藏文件路径,实现防盗链
未知 asp中对ip进行过滤限制函数   [ 日期:2006-09-25 17:02:29 ]   [ 来自:本站原创 ]

海外邮件中继,海外退信中继,美国高速VPS,不限流量VPN,邮局维护和管理,邮件网关,EMOS邮件中继,POSTFIX邮件中继,Winwebmail邮件中继,Winmail邮件中继,DBMail邮件中继,JDMail邮件中继,Exchange邮件中继,MDaemon邮件中继 淘宝店:http://shantan.taobao.com 云邮科技官网:www.yunrelay.com

【字体设置:
<% 
’获取访问者的地址 
ip=Request.ServerVariables("REMOTE_ADDR")  
’允许的IP地址段为10.0.0.0~10.68.63.255 
allowip1="10.0.0.0" 
allowip2="10.68.10.71" 
response.write checkip(ip,allowip1,allowip2) 

function checkip(ip,allowip1,allowip2) 
dim check(4) 
checkip=false 
ipstr=split(ip,".") 
allow1=split(allowip1,".") 
allow2=split(allowip2,".") 
if cint(allow1(0))>cint(allow2(0)) then ’判断IP地址段是否合法 
response.write "IP地址段出错!" 
exit function 
end if 
for i=0 to ubound(ipstr) 
if cint(allow1(i))<cint(allow2(i)) then 
if cint(allow1(i))=cint(ipstr(i)) then 
check(i)=true 
checkip=true 
exit for 
else 
if cint(ipstr(i))<cint(allow2(i)) then 
check(i)=true 
checkip=true 
exit for 
else 
if cint(ipstr(i))>cint(allow2(i)) then 
check(i)=false 
checkip=false 
exit for 
else 
check(i)=true 
checkip=true 
end if 
end if 
end if 
else 
if cint(allow1(i))>cint(ipstr(i)) or cint(allow1(i))<cint(ipstr(i)) then 
check(i)=false 
checkip=false 
if i<>ubound(ipstr) then 
exit for 
end if 
else 
check(i)=true 
end if 
end if 
next 
if (check(0)=true and check(1)=true and check(2)=true and check(3)=false) and (cint(allow2(2))>cint(ipstr(2))) then 
checkip=true 
end if 
end function 
%>

暂时没有评论
   发表评论 - 不要忘了输入验证码哦!
作者: 用户:  密码:  我要注册 验证码: 
为防止广告注册机程序,验证码不会自动显示,请点击此处显示或者(刷新)验证码!
评论:

禁止表情
禁止UBB
禁止图片
识别链接
识别关键字
确定发布?
最多可以输入200个字,目前你已经输入了0个字;你今日还可以发表10条评论!
 
   

CopyRight © 2008-2010 广东金融学院030904班 All Rights Reserved
Powered by www.030904.com