Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

how to take screenshots with selenium webdriver python

from selenium import webdriver
from time import sleep

driver = webdriver.Firefox()
driver.get('https://www.python.org')
sleep(1)

driver.get_screenshot_as_file("screenshot.png")
driver.quit()
print("end...")
Source by pythonbasics.org #
 
PREVIOUS NEXT
Tagged: #screenshots #selenium #webdriver #python
ADD COMMENT
Topic
Name
1+5 =