使用ASP經典和VB腳本payment.asp
我已經寫代碼來獲取數據。我發佈數據到第三方使用winhttprequest和它的提交成功,它的工作正常,但我的問題是:如何使用winhttprequest使用ASP經典
發佈數據後,在第三方頁面上,正在創建一個唯一的ID,我想要在同一頁上檢索payment.asp
我怎麼能檢索由第三方創造的唯一ID。
我的代碼如下:
<%
Dim http, url, data
Set http = Server.CreateObject("WinHttp.WinHttpRequest.5.1")
url = "https://www.instamojo.com/api/1.1/payment-requests/"
data = "amount=" & amount & "&buyer_name=" & buyer_name & "&purpose=" & purpose & "&redirect_url=" & redirect_url & "&phone=" & phone & "&send_email=" & send_email & "&send_sms=" & send_sms & "&email=" & email & ""
With http
Call .Open("POST", url, False)
Call .SetRequestHeader("Content-Type", "application/x-www-form-urlencoded")
Call .SetRequestHeader("X-Api-Key", "[X-Api-Key]")
Call .SetRequestHeader("X-Auth-Token", "[X-Auth-Token]")
Call .Send(data)
End With
If http.Status = 201 Then
Call Response.Write("succeeded: " & http.Status & " " & http.StatusText)
Else
Call Response.Write("Server returned: " & http.Status & " " & http.StatusText)
End If
%>
請幫助我。
你忘了[對話](http://chat.stackoverflow.com /間/ 113121 /討論-間LOKESH-purohit和-lankymart#),我們有大約ASPJSON和'http.ResponseText'?我猜也是。 – Lankymart