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

首頁 > 編程 > ASP > 正文

小偷程序2

2024-05-04 11:02:22
字體:
來源:轉載
供稿:網友
復制代碼 代碼如下:
<%
DJ54_path = "data/data.mdb" '數據庫地址
Set conn= Server.CreateObject("ADODB.Connection")
connstr = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source="&Server.MapPath(DJ54_path)
conn.Open connstr
Function GetHttpPage(HttpUrl)
If IsNull(HttpUrl)=True Or HttpUrl="$False$" Then
GetHttpPage="$False$"
Exit Function
End If
Dim Http
Set Http=server.createobject("MSXML2.XMLHTTP")
Http.open "GET",HttpUrl,False
Http.Send()
If Http.Readystate<>4 then
Set Http=Nothing 
GetHttpPage="$False$"
Exit function
End if
GetHTTPPage=bytesToBSTR(Http.responseBody,"GB2312")
Set Http=Nothing
If Err.number<>0 then
Err.Clear
End If
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

function mymid(byval A_strString,byval A_strPattern)
dim MM_objRegexp
dim MM_strExecute

set MM_objRegexp=new regexp
with MM_objRegexp
.Pattern=A_strPattern
.IgnoreCase=True
.Global=false
set MM_strExecute=.Execute(A_strString)
if MM_strExecute.count<>0 then
mymid=MM_strExecute(0).SubMatches(0)
end if
end with
mymid=trim(mymid)
set MM_objRegexp=nothing
end function

Function RegListGet(str,patrn,mysky)
set tempReg=new RegExp
tempReg.IgnoreCase=false
tempReg.Global=true
tempReg.Pattern=patrn
set matches=tempReg.execute(str)
for each match in matches
content=content&match.value&mysky
next
RegListGet=content
set matches=nothing
set tempReg=nothing
end Function

DJ54_SF = GetHttpPage("http://www.haosf.com/")
DJ54_SF = replace(DJ54_SF,vbcrlf,"")
DJ54_SF = replace(DJ54_SF,chr(10),"")
DJ54_SF = trim(mymid(DJ54_SF,"zjkf.asp"&chr(34)&"></script>(.+?)<script language=javascript src="&chr(34)&"txtj2.asp"&chr(34)&">"))
DJ54_SF = RegListGet(DJ54_SF,"<script>o(.+?)</script>","BT54")
DJ54_SF = replace(DJ54_SF,"/","")
DJ54_BT54_SF = split(DJ54_SF,"BT54")
response.write "采集成功 共采集當日"&Ubound(DJ54_BT54_SF)-1 &"個SF<br/>"

set rs = server.createobject("adodb.recordset")
sql = "select * from sfdata"
發表評論 共有條評論
用戶名: 密碼:
驗證碼: 匿名發表
主站蜘蛛池模板: 五峰| 深州市| 丹棱县| 廊坊市| 文登市| 安徽省| 饶平县| 关岭| 庄河市| 陆河县| 新龙县| 武穴市| 临邑县| 启东市| 忻城县| 梨树县| 池州市| 孟村| 蓬溪县| 禄劝| 靖宇县| 台前县| 阿鲁科尔沁旗| 台江县| 台南县| 阿拉善左旗| 长兴县| 绥滨县| 西城区| 彭阳县| 吉隆县| 田林县| 茶陵县| 贡山| 临湘市| 阿拉善盟| 仙桃市| 翁源县| 贺州市| 观塘区| 滦南县|