Monday, June 6, 2016

File Upload with Selenium

Yesterday, my brother asked me: "How to automatic upload a file with Selenium". Today, i had free time to solve it.
Try this code. I used python blinding:
from selenium import webdriver
url = "https://encodable.com/uploaddemo/"
driver = webdriver.Firefox()
driver.get(url)
element = driver.find_element_by_id("uploadname1")
element.send_keys("/home/habachnam/a.txt")
----------------------------------------------------------
Thanks for reading
--------------------------------------------------------------------------
Security Research
SecurityLab - Linux Lab -- Window and Cisco Lab
to be continued - I will update more.

No comments:

Install Xposed Inspector and Frida on Genymotion

Today i had some work with android. So i need trace application. I found 2 nice tool can help me: Xposed Inspector and Frida. To setup ther...