如何使用Python2.7从登录网站上浏览网页?

2024-04-24 07:09:21 发布

您现在位置:Python中文网/ 问答频道 /正文

我想从一个网站,在那里我必须先登录。 问题是,这里也有一个“机器人保护”(robotprotection)(所以我必须确认我不是一个机器人+一个recaptcha安全)

我怎样才能登录这个网站?在

这里是网站代码(谁是内容输入):

<input type="text" name="user"> <input type="password" name="password"> <div class="g-recaptcha" data-sitekey="6LdE0w0TAAAAANiqzyAxL1twu4X4ONWrmV0SMv7j" data-type="image"><div style="width: 304px; height: 78px;"><div><iframe src="https://www.google.com/recaptcha/api2/anchor?k=6LdE0w0TAAAAANiqzyAxL1twu4X4ONWrmV0SMv7j&amp;co=aHR0cHM6Ly93d3cub3B0ZW4uaHU6NDQz&amp;hl=hu&amp;type=image&amp;v=r20170613131236&amp;size=normal&amp;cb=g91tkr9x9ezg" title="recaptcha modul" width="304" height="78" frameborder="0" scrolling="no" sandbox="allow-forms allow-modals allow-popups allow-popups-to-escape-sandbox allow-same-origin allow-scripts allow-top-navigation"></iframe></div><textarea id="g-recaptcha-response" name="g-recaptcha-response" class="g-recaptcha-response" style="width: 250px; height: 40px; border: 1px solid #c1c1c1; margin: 10px 25px; padding: 0px; resize: none; display: none; "></textarea></div></div> <input class="standard" type="submit" value="Belépés">

我试过了,但没用。在


Tags: namedivinputdata网站responsetype机器人