Reputation: 921
I am currently using the following code to open a website:
import webbrowser
webbrowser.open('http://test.com')
I am now trying to save the open webpage as a .gif, any advise on how to do this please?
Upvotes: 1
Views: 595
Reputation: 473763
How about selenium
and its save_screenshot()
?
from selenium import webdriver
driver = webdriver.Firefox()
driver.get("http://test.com")
driver.save_screenshot("screenshot.png")
driver.close()
Upvotes: 3