国产探花免费观看_亚洲丰满少妇自慰呻吟_97日韩有码在线_资源在线日韩欧美_一区二区精品毛片,辰东完美世界有声小说,欢乐颂第一季,yy玄幻小说排行榜完本

首頁 > 學院 > 編程設計 > 正文

如何驗證IP地址?

2020-06-19 13:41:21
字體:
來源:轉載
供稿:網友

 sub chkIP(boardid)
   dim rsIP
   dim ipArr
   dim ignored
   dim i
   dim ip
   dim sql

   ip=Request.ServerVariables("REMOTE_ADDR")   
   ignored=false
   if not isempty(boardid) then   
     sql="select ignoreip from board where boardid="&cstr(boardid)
     set rsIP=conn.execute(sql)
     if not (rsIP.eof and rsIP.bof) then
      if instr(cstr(rsIP("ignoreip")&""),chr(13)&chr(10)) then
        iparr=split(rsIP("ignoreip"),chr(13)&chr(10))
        for i=0 to ubound(iparr)
          if trim(iparr(i))<>"" and left(ip,len(trim(iparr(i))))=trim(iparr(i)) then
           ignored=true
           exit for
          end if
        next
      else
        iparr=rsIP("ignoreip")
        if ip=trim(iparr) then
         ignored=true
        end if
      end if
     end if
     rsIP.close
   end if
   if ignored then
     response.write "<script language=javascript>window.location.href='ignoreip.htm'</script>"
   end if
 end sub

發表評論 共有條評論
用戶名: 密碼:
驗證碼: 匿名發表
主站蜘蛛池模板: 靖西县| 广丰县| 嫩江县| 昆明市| 淮滨县| 阳江市| 页游| 望江县| 赤水市| 敦化市| 方正县| 蒙城县| 哈密市| 英超| 遵义市| 巴东县| 柘城县| 镶黄旗| 凤阳县| 陆川县| 兰溪市| 承德市| 手机| 涟水县| 汉阴县| 钟祥市| 景宁| 永嘉县| 镇平县| 德清县| 黑山县| 托里县| 鄂托克前旗| 越西县| 罗源县| 康定县| 普定县| 年辖:市辖区| 盐边县| 宁陕县| 鹤峰县|