Attribute VB_Name = "HTTP2" 'An HTTP Client Module Written By Robbie Saunders Function Post(thePage, theReferer, theHost, theCookie, theContent) Post = "" Post = Post & "POST " & thePage & " HTTP/1.0" & vbCrLf Post = Post & "Accept: image/gif, image/x-xbitmap, image/jpeg, image/pjpeg, application/msword, application/vnd.ms-powerpoint, application/vnd.ms-excel, */*" & vbCrLf If theReferer <> "" Then Post = Post & "Referer: " & theReferer & vbCrLf Post = Post & "Accept -Language: en -us" & vbCrLf Post = Post & "Content-Type: application/x-www-form-urlencoded" & vbCrLf Post = Post & "Accept -Encoding: gzip , deflate" & vbCrLf Post = Post & "User-Agent: Mozilla/4.0 (compatible; MSIE 5.01; Windows NT; MSOCD; AtHome020)" & vbCrLf If theHost <> "" Then Post = Post & "Host: " & theHost & vbCrLf Post = Post & "Content-Length: " & Len(theContent) & vbCrLf Post = Post & "Proxy -Connection: Keep -Alive" & vbCrLf Post = Post & "Pragma: no -cache" & vbCrLf If theCookie <> "" Then Post = Post & "Cookie: " & theCookie & vbCrLf Post = Post & "" & vbCrLf Post = Post & theContent & vbCrLf End Function Function Gett(thePage, theReferer, theHost, theCookie) Gett = "" Gett = Gett & "GET " & thePage & " HTTP/1.0" & vbCrLf Gett = Gett & "Accept: image/gif, image/x-xbitmap, image/jpeg, image/pjpeg, application/msword, application/vnd.ms-powerpoint, application/vnd.ms-excel, */*" & vbCrLf If theReferer <> "" Then Gett = Gett & "Referer: " & theReferer & vbCrLf Gett = Gett & "Accept -Language: en -us" & vbCrLf Gett = Gett & "Accept -Encoding: gzip , deflate" & vbCrLf Gett = Gett & "User-Agent: Mozilla/4.0 (compatible; MSIE 5.01; Windows NT; MSOCD; AtHome020)" & vbCrLf If theHost <> "" Then Gett = Gett & "Host: " & theHost & vbCrLf Gett = Gett & "Proxy -Connection: Keep -Alive" & vbCrLf Gett = Gett & "Pragma: no -cache" & vbCrLf If theCookie <> "" Then Gett = Gett & "Cookie: " & theCookie & vbCrLf Gett = Gett & "" & vbCrLf End Function Function AIMGet(thePage, theReferer, theHost) AIMGet = "" AIMGet = AIMGet & "GET " & thePage & " HTTP/1.0" & vbCrLf If theHost <> "" Then AIMGet = AIMGet & "Host: " & theHost & vbCrLf AIMGet = AIMGet & "If-Modified-Since:" & vbCrLf AIMGet = AIMGet & "Accept:*/*" & vbCrLf If theReferer <> "" Then AIMGet = AIMGet & "Referer: " & theReferer & vbCrLf AIMGet = AIMGet & "User-Agent: AIM/30 (Mozilla 1.24b; Windows; I; 32-bit)" & vbCrLf AIMGet = AIMGet & vbCrLf End Function Function GrabCookie(theStuff, theCookie) Dim A1, A2 A1 = Split(theStuff, vbCrLf) For i = 0 To UBound(A1) If Len(A1(i)) >= 12 + Len(theCookie) Then If Left(A1(i), 12 + Len(theCookie)) = "Set-Cookie: " & theCookie Then A2 = Split(A1(i), ";") GrabCookie = Right(A2(0), Len(A2(0)) - 12) Exit Function End If End If DoEvents Next i GrabCookie = False End Function