원 격 페이지 의 모든 내용 1/2 페이지 를 한꺼번에 다운로드 합 니 다.
4169 단어 원 격 페이지 의 모든 내용
<%'시간 초과 설정 Server.ScriptTimeout=9999'\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#'파일 저장 함수'\#\#\#\#\#\#\#\#\#\#\#\#\#\##\##\###\#기능 SaveToFile(from,tofile)on error resume nextdim geturl,obsStream,imgs geturl=trim(from) Mybyval=getHTTPstr(geturl) Set objStream = Server.CreateObject("ADODB.Stream") objStream.Type =1 objStream.Open objstream.write Mybyvalobjstream.SaveToFile tofile,$<<<>0 이 err. clear end function'\###\####\#####\#####\####\####\###\#####\####\#####\###\###\####\#####\######\##################\########################################################################################l,i,1)) if code<0 Then code = code + 65536 If code>255 Then geturlencodel=geturlencodel&"%"&Left(Hex(Code),2)&"%"&Right(Hex(Code),2) else geturlencodel=geturlencodel&mid(Url,i,1)end if next end function'\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#'XML 원 격 페이지 가 져 오기 시작'\#\#\#\#\#\#\#\#\#\#\#\##\#####\#기능 getHTTPPage(url)on error resume next dim http set http=Server.createobject("Msxml2.XML HTTP")Http.open"GET",url,false Http.send() if Http.readystate<>4 then exit function getHTTPPage=bytes2BSTR(Http.responseBody) set http=nothing if err.number<>0 then err.Clear end function Function bytes2BSTR(vIn) dim strReturn dim i,ThisCharCode,NextCharCode strReturn = "" For i = 1 To LenB(vIn) ThisCharCode = AscB(MidB(vIn,i,1)ThisCharCode<&H80 Then strReturn=strReturn&Chr(ThisCharCode)Else NextCharCode=AscB(MidB(vIn,i+1,1)strReturn=strReturn&Chr(CLng(ThisCharCode)*&H100+CInt(NextCharCode)i=i+1 End If Next bytes2BSTR=strReturn End Function'\#\#\#\##\#\##\#\#\##\#\##\##\##\##\###\##XML 원 격 페이지 끝 가 져 오기,XML이 부분 은 도둑 프로그램 이 모두 통용 하 는 부분 입 니 다.a=split(filename,"/") getFileName=lcase(fileExt_a(ubound(fileExt_a))) if instr(getFileName,"?")>0 thengetFileName=left(getFileName,instr(getFileName,"?")-1)end ifelsegetFileName=filenamend ifend function'\#\#\#\#\#\#\#\#\#\#\#\#\#\#'원 격 페이지 함수 가 져 오기'\#\#\#\#\#\#\#\#\#\#\#\#\##\#기능 getHTTPstr(url)오류 resume next dim http set http=server.createobject("MSXML 2.XML HTTP")Http.open"GET",url,false Http.send()if Http.readystate<>4 then exit function getHTTPstr=Http.response Body set http=nothing if err.number<>0 then err.clear end function'\#\#\#\#\#\#\#\#\#\#\#\##\#'FSO 처리 함수,디 렉 터 리 만 들 기'\#\#\#\#\#\#\##\#\#\#\#\##\##\##\######\#Function CreateDIR(ByVal Localpath)'디 렉 터 리 만 드 는 프로그램1 급 생 성 On Error Resume Next LocalPath=Replace(LocalPath,"\","/")Set FileObject=server.CreateObject("Scripting.FileSystem Object")patharr=Split(LocalPath,"/")pathlevel = UBound(patharr) For I = 0 To path_level If I = 0 Then pathtmp = patharr(0) & "/" Else pathtmp = pathtmp & patharr(I) & "/" cpath = Left(pathtmp, Len(pathtmp) - 1) If Not FileObject.FolderExists(cpath) Then FileObject.CreateFolder cpath Next Set FileObject = Nothing If Err.Number <> 0 Then CreateDIR = False Err.Clear Else CreateDIR = True End If End Function function GetfileExt(byval filename) fileExt_a=split(filename,".") GetfileExt=lcase(fileExt_a(ubound(fileExt_))end function'\##\####\###\###\###\###\###\####\######\###\###\###\###\###\###\####\####\##\####\#####\######\#######\######\#######\######\#####\######\############\###########################################,start)end ifurl=urlhead&urlelseif left(str,3)="../"thenstr 1=mid(str,inStrRev(str,"../")+2)ar=split(str,"../")lv=ubound(ar)+1ar=split(path,"/")url="/"for i=1 to (ubound(ar)-lv)url=url&ar(i)nexturl=url&str1url=urlhead&urlelseurl=urlhead&strend ifgetvirtual=urlend function
1 2 다음 페이지 전문 을 읽다