selenium login to website
# Dependencies
from selenium import webdriver
driver = webdriver.Chrome()
# Target page
driver.get("https://ilovefluffycats.com/authentication/signon")
assert "cats" in driver.title
# Complete username
username = driver.find_element_by_id("uid")
username.clear()
username.send_keys("mrcats")
# Complete password
password = driver.find_element_by_name("pwd")
password.clear()
password.send_keys("catskillz")
# Click login
driver.find_element_by_name("submitButton").click()
# Also possible to click by text
# driver.find_element_by_link_text("Grumpy cats").click()