1
多屏预期,但我只得到了第一个。 这里是我的代码,我试图Python中,多屏幕快照使用PhantomJS
from selenium import webdriver
client_urls =
['https://www.facebook.com/','http://www.https://stackoverflow.com']
for client_url in client_urls:
driver = webdriver.PhantomJS('C:\\phantomjs-2.1.1-windows\\bin\\phantomjs.exe')
driver.get(client_url)
print(client_url)
screen = client_urls
driver.get_screenshot_as_file('C:\\Users\\xyz\\output\\b.png')
driver.quit()'''
我会尝试PIL,但该URL可能是一个错字,错误对不起 –