Python 3.x 使用selenium和Python单击Flash按钮
我正在编写一个脚本,它应该可以为我下载3000个文件。我已经用我的方式完成了登录和所有这些东西,但是实际的下载按钮=“提取数据”是用flash编写的(网站的其余部分不是)。有没有办法使用selenium单击此按钮?我正在运行Python 3.4。在OSx上Python 3.x 使用selenium和Python单击Flash按钮,python-3.x,selenium,flash,automation,Python 3.x,Selenium,Flash,Automation,我正在编写一个脚本,它应该可以为我下载3000个文件。我已经用我的方式完成了登录和所有这些东西,但是实际的下载按钮=“提取数据”是用flash编写的(网站的其余部分不是)。有没有办法使用selenium单击此按钮?我正在运行Python 3.4。在OSx上 #!/usr/bin/python3 from selenium import webdriver from selenium.webdriver.common.keys import Keys from bs4 import Beautif
#!/usr/bin/python3
from selenium import webdriver
from selenium.webdriver.common.keys import Keys
from bs4 import BeautifulSoup
import os
import re
import requests
url = "http://www.votewatch.eu/signin.php?
return_path=http%3A%2F%2Fwww.votewatch.eu%2Fen%2Fterm8-protocol-to-
the-eu-uzbekistan-partnership-and-cooperation-agreement-accession-of-
croatia-draft-legis.html" #TestURL
driver = webdriver.Chrome(executable_path=r"/Users/mypath/Desktop/Uni
/ChromeDriver/ChromeDriver") #Chrome Driver
driver.implicitly_wait(30)
driver.get(url)
elem1 = driver.find_element_by_name("login_username")
elem1.clear()
elem1.send_keys("my_username")
elem2 = driver.find_element_by_name("login_password")
elem2.send_keys("mypassword")
driver.implicitly_wait(30)
login_click = driver.find_element_by_class_name("blue_button_link")
login_click.click()
extract_data_button = ??????? Flash magic ?????
非常感谢 selenium不支持Flash,我现在已经找到了解决方法。我使用按钮上的开发者chrome工具来识别它的类名。