小编fap*_*apw的帖子

XMLHTTP请求(POST)使用VBScript从Web站点检索数据

亲爱的同事们!我需要你的帮助.

最重要的是,这不是广告.我尝试在铁路车票网站http://booking.uz.gov.ua/en/上发出POST请求,以了解当前日期是否有门票.但是......有问题.我正在使用VBScript发出请求.要知道在网站上发送的HTTP标头和POST请求,我使用的是Chrome内置开发工具.

这是我的脚本:

    Dim URL
    Dim URL2
    Dim URL3
    Dim sRequest
    Dim sCookies

    'This is web page where I need to enter information.
    URL = "http://booking.uz.gov.ua/en/"
    'This is path that Chrome shows to send POST request.
    URL2 = "http://booking.uz.gov.ua/en/purchase/search/"
    'Optional URL, Chrome shows this link near of URL2. I think this is .js that works                 on info I enter on web site (URL).
    'URL3 = "http://booking.uz.gov.ua/i/js/common.138.js"
    'POST request that Chrome shows to send.
    sRequest ="station_id_from=2200001&station_id_till=2208001&station_from=Kyiv&station_till=Odesa&date_        dep=09.19.2013&time_dep=00%3A00&search="
    'Here I'm …
Run Code Online (Sandbox Code Playgroud)

vbscript post get xmlhttprequest request

3
推荐指数
1
解决办法
9858
查看次数

标签 统计

get ×1

post ×1

request ×1

vbscript ×1

xmlhttprequest ×1