This package is used to Clipped Images of Html Elements of Selenium Webdriver
Project description
Slenium Screenshot :
The Selenium Screenshot is used to clipped Html Element using Selenium Webdriver
Supported WebDriver :
- Chromedriver
- IEDriverServer
Installations :
pip install Selenium-Screenshot
This Package Supported for Python 3.*
How to Use :
For Full Page ScreenShot :
from Screenshot import Screenshot_Clipping
from selenium import webdriver
ob=Screenshot_Clipping.Screenshot()
driver = webdriver.Chrome()
url = "https://github.com/sam4u3/Selenium_Screenshot/tree/master/test"
driver.get(url)
img_url=ob.full_Screenshot(driver, save_path=r'.', image_name='Myimage.png')
print(img_url)
driver.close()
driver.quit()
For Html Element Clipping :
from Screenshot import Screenshot_Clipping
from selenium import webdriver
ob=Screenshot_Clipping.Screenshot()
driver = webdriver.Chrome()
url = "https://github.com/sam4u3/Selenium_Screenshot/blob/master/Screenshot/Screenshot_Clipping.py"
driver.get(url)
element=driver.find_element_by_class_name('signup-prompt')
img_url=ob.get_element(driver, element, r'.')
print(img_url)
driver.close()
driver.quit()
For Html Element Clipping with Hiding Element :
from Screenshot import Screenshot_Clipping
from selenium import webdriver
ob=Screenshot_Clipping.Screenshot()
driver = webdriver.Chrome()
url = "https://github.com/sam4u3"
driver.get(url)
Hide_elements=['class=avatar width-full height-full avatar-before-user-status'] # Use full class name
img_url=ob.full_Screenshot(driver, save_path=r'.', elements=Hide_elements, image_name='Myimage.png')
print(img_url)
driver.close()
driver.quit()
Limitation :
- Screenshot can take only 10000 of height of website
Contact Information :
Email: sayarmendis26@gmail.com
Donation :
If you have found my softwares to be of any use to you, do consider helping me pay my internet bills. This would encourage me to create many such softwares :)
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Close
Hashes for Selenium-Screenshot-1.6.0.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | aea6ace4c72221d42c3ac11b815742ad0f00c3ca670c4a0c16ef253310feb3d0 |
|
MD5 | a7a1feda732b750582dfee9b07138cf0 |
|
BLAKE2b-256 | 6cb2deab3d8136ba766f5c7c72bdbc64b9f4df5641e742fbcefa32d76fb327d8 |