複製代碼代碼如下:
<%
'--------------------------------------------------------------
Dbname="../data/flash.mdb"'更改數據庫文件位置,強烈建議更改為.asp的文件!
SetConn=Server.CreateObject("ADODB.Connection")
Connstr="Provider=Microsoft.Jet.OLEDB.4.0;DataSource="&Server.Mappath(Dbname)
Conn.OpenConnstr
'------------------------------------------------------------
SetList=Conn.Execute("Select*FromSystem")
WebName=List("WebName")
WebUrl=List("WebUrl")
webemail=List("webemail")
zzname=List("zzname")
qq=List("webqq")
%>
<%
Server.ScriptTimeOut=999999999
%>
<%
ifrequest("overid")=""then
response.write"結束ID不可為空"
response.end
elseifrequest("download")=""then
response.write"請選擇是否下載"
response.end
endif
ifrequest("id")=request("overid")then
response.write"採集任務結束"
response.end
endif
gourl1=request("id")
gourl1=gourl1+1
%>
<%
functionGetPy(Str)
fori=1tolen(Str)
GetPy=GetPy&GetPyChar(mid(Str,i,1))
next
endfunction
FunctionGetURL(url)
SetRetrieval=CreateObject("Microsoft.XMLHTTP")
WithRetrieval
.Open"GET",url,False
.Send
GetURL=bytes2bstr(.responsebody)
iflen(.responsebody)<100then
response.write"獲取遠程文件<ahref="&url&"target=_blank>"&url&"</a>失敗。"
response.write"<metahttp-equiv=""refresh""content=""0;URL=getid.asp?id="&gourl1&""">"
response.end
endif
EndWith
SetRetrieval=Nothing
EndFunction
functionbytes2bstr(vin)
strreturn=""
fori=1tolenb(vin)
thischarcode=ascb(midb(vin,i,1))
ifthischarcode<&h80then
strreturn=strreturn&chr(thischarcode)
else