在使用Python Request的提示中单击确定按钮

时间:2019-02-27 00:35:02

标签: python python-3.x automation python-requests click

因此,基本上,我想使用Python的请求模块自动执行此操作

登录网站>超时>退出

我已经使用“ .post()”代码完成了网站登录的自动化。 但是我被困在“超时”按钮上,因为当我尝试使用Google Chrome浏览器的Inspect检查它时,它不显示任何表单数据。我使用了相同的“ .post()”代码。它实际上是行不通的。我注意到有一个 PROMPT WINDOW ,其中包含“确定”和“取消”按钮,您需要单击“确定”才能继续操作,这也是检查中唯一记录的网络活动单击菜单。这是Chrome的“检查是否有帮助”的结果。

GENERAL
    Request URL: https://blah.blah.com/auth/WebLogSubmit.igx?type=OUT
    Request Method: POST
    Status Code: 200 OK
    Remote Address: 1.11.11.1
    Referrer Policy: no-referrer-when-downgrade
RESPONSE HEADERS
    Cache-Control: no-cache, no-store, must-revalidate
    Connection: keep-alive
    Content-Encoding: gzip
    Content-Length: 320
    Content-Type: text/html;charset=utf-8
    Date: Tue, 26 Feb 2019 23:38:49 GMT
    Pragma: no-cache
    Server: Jetty(9.4.14.v20181114)
    Strict-Transport-Security: max-age=0
    X-Content-Type-Options: nosniff
    X-Frame-Options: SAMEORIGIN
    X-XSS-Protection: 1; mode=block
REQUEST HEADERS
    Accept: */*
    Accept-Encoding: gzip, deflate, br
    Accept-Language: en-US,en;q=0.9
    Connection: keep-alive
    Content-Length: 0
    Cookie: _lastloggeddate=off; _lastloggeddate=on; JSESSIONID=0HVVf1JLkZLWllMLbSLoG2o14ZXLHiFB4yq2am+VAHBAsKGAt0Avkgacwe9qly7UBF3Ga2As/R0+ChgF7GEQJA==; AWSELB=E204C7B7ED3B76034B4DCF9D0AA226E459847982290B43FAF19399EF5AC1BC948D033EAAF9221BD4FB9718F6; _ga=GA1.2.1551220185; _gid=GA1.2.1551220185
    Host: blah.blah.com
    Origin: https://blah.blah.com
    Referer: https://blah.blah.com/auth/index.htm
    User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/72.0.3626.119 Safari/537.36
    X-Requested-With: XMLHttpRequest
QUERY STRING PARAMETERS
    type: OUT

    WebLogSubmit.igx?type=OUT

0 个答案:

没有答案
相关问题