Created
September 13, 2020 07:52
-
-
Save Ashutoshkumargautam/121e60b28caa4b73acb39edd40f6ceac to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from selenium import webdriver | |
def loginBOT(usr, pas): | |
br = webdriver.Firefox() | |
br.get("https://web.facebook.com/") | |
user = br.find_element_by_css_selector("#email") | |
user.clear() | |
user.send_keys(usr) | |
passwd = br.find_element_by_css_selector("#pass") | |
passwd.clear() | |
passwd.send_keys(pas) | |
btn = br.find_element_by_css_selector("#u_0_5") | |
btn.click() | |
if __name__ == "__main__": | |
loginBOT('username or email', 'yourpassword') |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment