正在加载中...

关闭
请选择需要拨打的号码

信息详页

返回
ASP模拟GET提交数据的方法
Function 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


Function HttpGet(weburl)
    Set Retrieval = CreateObject("Msxml2.ServerXMLHTTP")
    With Retrieval
        .Open "GET", weburl, False, "", ""
        .Send
        HttpGet = .ResponseBody
    End With
    HttpGet = BytesToBstr(HttpGet,"UTF-8")
    Set Retrieval = Nothing
End Function

Response.Write(HttpGet("http://www.baidu.com/?shouji=15934103108&userid=9&neirong=亲,您的订单已提交"))