# 查看ip是否有用
# driver.get("http://httpbin.org/ip")
# print(driver.page_source)
driver.get("https://www.wjx.cn/m/23272865.aspx")
driver.find_element_by_xpath("//*[@id='div1']/div[2]/div[1]/span/a").click()
for i in range(1, 3):
driver.find_element_by_xpath("//*[@id='div%d']/div[2]/div[1]/span/a" % i).click()
list1 = list(range(3, 46))
del list1[7]
del list1[7]
for i in list1:
driver.find_element_by_xpath("//*[@id='div%d']/div[2]/table/tbody/tr[2]/td[1]/a" % i).click()
driver.find_element_by_xpath("//*[@id='ctlNext']").click()
if __name__ == "__main__":
for i in range(5):
# chromeOptions = webdriver.ChromeOptions()
# 设置代理
# ips = ['119.183.211.171:1245',
# '118.254.79.191:2386',
# '115.153.172.79:1659',
# '111.74.234.4:9756',
# '119.7.218.46:5974',
# ]'''
# chromeOptions.add_argument("--proxy-server=http://" + ips[i])
driver = webdriver.Chrome()
doQuestion()