Retrieiving Cookies and Sending Cookies and Post Variables in VBScript

前端 未结 1 1728
轻奢々
轻奢々 2020-12-19 09:18

I\'m trying to submit some post data form using vbscript. The site I\'m posting it to contains some java, and having poked around in the headers, I notice it\'s sending a co

相关标签:
1条回答
  • 2020-12-19 09:44

    You could get via http.getResponseHeader("Set-Cookie") or parsing http.getAllResponseHeaders(). Then, you should add cookie values to request header via http.setRequestHeaders "Cookie", "JSESSIONID=XXXXXXXXXXXXXXXXXXXXX; Path=/Page" on next requests.
    So, there is another option (if i'm not wrong), using CreateObject("WinHttp.WinHttpRequest.5.1").

    It's capable to remember the cookies had previously to use on next requests as long as you use the same instance.

    0 讨论(0)
提交回复
热议问题