채집 에 관 한 함수 몇 개 제공(ASP)
3356 단어 채집 에 관 한 함수 몇 개 제공(ASP)
''''%%%''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''gb 2312 로 UTF-8 이 라면...UTF-8''''''''주석 끝''''''''''''''기능 getHTTPPage(Path)t=GetBody(Path)getHTTPPage=Bytes ToBstr(t,gb 2312)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 FunctionFunction 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%>