asp中xmlhttp組件發(fā)包
asp中xmlhttp組件發(fā)包
寫的一個(gè)小偷函數(shù),注意紅色代碼部分,其他的自己添加吧!
Function PostHttpPageFrom(HttpUrl,stra,FromUrl)
Dim Http
Set Http=server.createobject("MSXML2.XMLHTTP")
Http.open "POST",HttpUrl,False
Http.setrequestheader "content-length",len(stra) Http.setrequestheader "content-
type","application/x-www-form-urlencoded"
Http.setrequestheader "Referer",FromUrl
Http.send stra
If Http.Readystate<>4 then
Set Http=Nothing
GetHttpPage="$False$"
Exit function
End if
PostHttpPageFrom=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.Open1 d)
objstream.Write body
objstream.Position = 0
objstream.Type = 2
objstream.Charset = Cset
BytesToBstr = objstream.ReadText
objstream.Close
set objstream = nothing
End Function
相關(guān)文章
利用xmlhttp和adodb.stream加緩存技術(shù)下載遠(yuǎn)程Web文件
利用xmlhttp和adodb.stream加緩存技術(shù)下載遠(yuǎn)程Web文件...2006-06-06
遠(yuǎn)程圖片自動(dòng)按文件夾上傳到服務(wù)器-默飛出品
遠(yuǎn)程圖片自動(dòng)按文件夾上傳到服務(wù)器-默飛出品...2006-06-06
用正則和xmlHttp實(shí)現(xiàn)的asp小偷程序
用正則和xmlHttp實(shí)現(xiàn)的asp小偷程序...2007-03-03
使用xmlHttp結(jié)合ASP實(shí)現(xiàn)網(wǎng)頁(yè)的異步調(diào)用
使用xmlHttp結(jié)合ASP實(shí)現(xiàn)網(wǎng)頁(yè)的異步調(diào)用...2006-06-06
Asp定時(shí)執(zhí)行操作 Asp定時(shí)讀取數(shù)據(jù)庫(kù)(網(wǎng)頁(yè)定時(shí)操作詳解)
由于目前部分網(wǎng)頁(yè)語(yǔ)言的限制,在定時(shí)操作上有一定的困難,但是經(jīng)過我多次的求證,發(fā)現(xiàn)第四種方法無(wú)疑是效果最好的,最省心的。2009-10-10

