發(fā)布時(shí)間:2018-12-25
欄目:其他
前兩天想寫一段同ip反查域名的代碼應用創新,在很多網(wǎng)站上找了半天提高,最后在一個(gè)英文站上看見可以通過live.com的搜索結(jié)果提取此類信息,于是寫了下面一段:程序只是測(cè)試成功的特性,沒有進(jìn)行優(yōu)化交流,查詢效率有點(diǎn)低!
<%
Dim strPage
Function GetPage2(Path)
t = GetBody(Path)
GetPage2=BytesToBstr(t,"GB2312")
End function
Function GetBody(url)
on error resume next
Set Retrieval = CreateObject("Microsoft.XMLHTTP")
With Retrieval
.Open "Get", url, False, "", ""
.Send
GetBody = .ResponseBody
郵箱反查域名助手End With
Set Retrieval = Nothing
End Function
Function BytesToBstr(body,Cset)
dim objstream
set objstream = Server.CreateObject("adodb.stream")
objstream.Type = 1
objstream.Mode =3
objstream.Open
objstream.Write body
objstream.Position = 0
objstream.Type = 2
郵箱反查域名助手objstream.Charset = Cset
BytesToBstr = objstream.ReadText
objstream.Close
set objstream = nothing
郵箱反查域名助手End Function
Public Function GetDomain(TempStr,matchstr)
set reg=new Regexp
reg.Multiline=True
reg.Global=True
reg.IgnoreCase=true
reg.Pattern=matchstr
Set matches = reg.execute(TempStr)
For Each match in matches
郵箱反查域名助手if not instr(GetDomain,match.Value)>0 then
GetDomain=GetDomain&match.Value
end if
Next
End Function
dim i
郵箱反查域名助手for i=1 to 15
strPage=strPage&GetPage2(" http://cnweb.search.live.com/results.aspx?q=ip%3A59.54.54.167&first="&i&"1")
郵箱反查域名助手next
strPage=GetDomain(strPage,"(.*?)\/")
strPage=replace(strPage,"","
")
strPage=replace(strPage,"strPage=replace(strPage,"/","
")
strPage=replace(strPage,"<<","<")
strPage=GetDomain(strPage,"<li(.*?)\/li>")
response.write strPage
%>
上一篇:觀測(cè)數(shù)據(jù)的可靠性取決于數(shù)據(jù)采集系統(tǒng)和傳感器提供堅實支撐、檢波器等探測(cè)終端
下一篇:強(qiáng)強(qiáng)聯(lián)合 共同布局CDN技術(shù)落地云計(jì)算市場(chǎng)
文章地址:http://www.61py.com/article/other/tipfcymASPdmfx.html

- 1通王CMS 2.0簡(jiǎn)介
- 2黑帽網(wǎng)站排名檢測(cè)
- 3MySQL中經(jīng)典的too many connection怎么破
- 4網(wǎng)易郵箱洪陸駕:反垃圾郵件需集合全球力量
- 5站群友鏈換鏈神器
- 6云勢(shì)軟件VirgoEDC助力安徽萬邦、迪時(shí)咨詢等公司臨床試驗(yàn)數(shù)據(jù)采集智能化
- 7Authorize 屬性通過聲明的方式保護(hù)控制器或其部分方法
- 8域名是稀有資源約定管轄,好的域名數據,在一定時(shí)期內(nèi)會(huì)越來越升值
- 9解析常見的PHP緩存技術(shù)有哪些
- 10對(duì)ASP.NET程序員非常有用工具