【问题标题】:Click on a link and then change ip with python mechanize单击一个链接,然后使用 python mechanize 更改 ip
【发布时间】:2014-04-20 22:15:22
【问题描述】:

有没有可能用python写一个脚本,在网站上寻找目标链接,然后点击,最后循环更改ip-address等等?

一些例子?

我试图了解机械化,但互联网上没有文档,谢谢

【问题讨论】:

    标签: python click ip mechanize


    【解决方案1】:

    如果您的集合中有大量代理,您可以通过它进行连接,我不明白您为什么不能这样做。

    proxies = {"proxy_one", "proxy_two", "proxy_three"}
    // Not a python guy, this syntax could be completely wrong and I'm sorry, please feel free to edit this
    
    for proxy in proxies:
      req = mechanize.Request("http://www.google.com")
      req.set_proxy(element,"http")
      mechanize.urlopen(req)
    

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 2021-04-04
      • 1970-01-01
      • 1970-01-01
      • 2011-09-27
      • 1970-01-01
      • 1970-01-01
      • 2012-07-23
      相关资源
      最近更新 更多