ASP http

Function   GetURL(url)  
            GetURL=""  
          Set   Retrieval   =   Server.CreateObject("Microsoft.XMLHTTP")  
                      With   Retrieval  
                      .Open   "GET",   url,   false  
      .setRequestHeader   "Content-Type","application/x-www-form-urlencoded"  
                      .Send  
                      GetURL   =   .ResponseBody  
                      End   With  
          Set   Retrieval   =   Nothing  
  GetURL=bstr(GetURL)  
  End   Function  
   
  Function   bstr(vIn)  
   
  Dim   strReturn,i,ThisCharCode,innerCode,Hight8,Low8,NextCharCode  
  strReturn   =   ""  
   
  For   i   =   1   To   LenB(vIn)  
  ThisCharCode   =   AscB(MidB(vIn,i,1))  
  If   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  
   
  bstr   =   strReturn    
  End   Function

你可能感兴趣的:(Microsoft,asp)