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

首頁(yè) > 學(xué)院 > 軟件教程 > 正文

純真ip數(shù)據(jù)庫(kù)轉(zhuǎn)換為(access)使用圖文教程

2020-07-18 16:09:59
字體:
來(lái)源:轉(zhuǎn)載
供稿:網(wǎng)友
第一步:其實(shí)制作查詢IP工具的時(shí)候,已經(jīng)有PHP可以完美直接讀取QQWry.Dat文件了,演示地址:http://tools.VeVB.COm/ip/index.php
              源碼下載地址 PHP IP查詢系統(tǒng)(純真IP數(shù)據(jù)庫(kù)) v2.1

第二步:IPLook 1.5.exe就是可以將 QQWry.Dat 文件,轉(zhuǎn)出txt文件的軟件。(如果是看了武林網(wǎng)的文章來(lái)的朋友,下面的輸出格式,需要選擇IP以無(wú)符號(hào)整數(shù)表示)


第三步:將剛導(dǎo)出的txt文件轉(zhuǎn)成數(shù)據(jù)庫(kù)的工具


其它的就很方便修改了
下面是asp讀取access的代碼,注意字段的名稱需要簡(jiǎn)單的修改下

復(fù)制代碼
代碼如下:

<%'IP
Public Function address(sip)
Dim aConnStr,aConn,adb
Dim str1,str2,str3,str4
Dim num
Dim country,city
Dim irs,SQL
If IsNumeric(Left(sip,2)) Then
If sip="127.0.0.1" Then sip="192.168.0.1"

str1=Left(sip,InStr(sip,".")-1)
sip=mid(sip,instr(sip,".")+1)
str2=Left(sip,instr(sip,".")-1)
sip=Mid(sip,InStr(sip,".")+1)
str3=Left(sip,instr(sip,".")-1)
str4=Mid(sip,instr(sip,".")+1)
If isNumeric(str1)=0 or isNumeric(str2)=0 or isNumeric(str3)=0 or isNumeric(str4)=0 Then
Else
num=CLng(str1)*16777216+CLng(str2)*65536+CLng(str3)*256+CLng(str4)-1
adb = "ip.mdb"
aConnStr = "Provider = Microsoft.Jet.OLEDB.4.0;Data Source = " & Server.MapPath(adb)
Set AConn = Server.CreateObject("ADODB.Connection")
aConn.Open aConnStr

sql="select * from ip where startip <="&num&" and endip >="&num&""
Set irs=aConn.execute(sql)
If irs.EOF And irs.bof Then
local="尚未收錄"
Else
local=irs("country")&irs("local")
End If
Set irs=Nothing
Set aConn = Nothing
SqlQueryNum = SqlQueryNum+1
End If
address=local
Else
address="未知"
End If
End Function
linkip = Request.ServerVariables("HTTP_X_FORWARDED_FOR")
If linkip = "" Then linkip = Request.ServerVariables("REMOTE_ADDR")
ip=request.form("ip")
%>
<dd style="text-align:center"><span class="bot">+ + 您 的 IP : [ <%=linkip%> ] 來(lái) 自 : <%=address(linkip)%> + +
<%=Request.ServerVariables("HTTP_USER_AGENT")%></span>
<form method="post" target="_top" action="ip.asp" name="ipform" onsubmit="return checkIP();">
請(qǐng)輸入要查詢的IP:
<input type="text" name="ip" size="36" value="<%=ip%>" class=input>&nbsp;<input type="submit" value="點(diǎn)擊查詢" class=but></form>
<%
if request.ServerVariables("REQUEST_METHOD")="POST" then%>
<font color="#ff0000"><strong>查詢結(jié)果 : <%=ip%> ==>> <%=ip%> ==>> <%=address(ip)%></strong></font>
上面四項(xiàng)依次顯示的是 : 原始輸入內(nèi)容 <strong>==>></strong> 獲取的IP地址 <strong>==>></strong> IP的物理位置
<%end if%>

文中所用工具打包下載 QQ IP數(shù)據(jù)庫(kù) 純真版 access(ip雙精度)數(shù)據(jù)庫(kù)制作工具
發(fā)表評(píng)論 共有條評(píng)論
用戶名: 密碼:
驗(yàn)證碼: 匿名發(fā)表
主站蜘蛛池模板: 徐汇区| 怀化市| 泰州市| 利川市| 沭阳县| 顺平县| 喀什市| 于田县| 九江市| 武隆县| 丹东市| 阿鲁科尔沁旗| 汕尾市| 余干县| 东阳市| 石阡县| 奎屯市| 同心县| 姜堰市| 天台县| 白山市| 海伦市| 宝坻区| 丘北县| 陆河县| 巴塘县| 天水市| 彰化县| 临沂市| 吉林省| 定安县| 渑池县| 伊宁市| 安达市| 神农架林区| 东源县| 南雄市| 灌阳县| 宁德市| 宣城市| 松江区|