Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save hudsonbrendon/d1c830a9b3df83304f5620d009a3a0c7 to your computer and use it in GitHub Desktop.
Save hudsonbrendon/d1c830a9b3df83304f5620d009a3a0c7 to your computer and use it in GitHub Desktop.
facebook_login.py
# coding: utf-8
from selenium import webdriver
from selenium.webdriver.common.keys import Keys
firefox = webdriver.Firefox()
firefox.get('https://www.facebook.com')
email = firefox.find_element_by_name('email')
password = firefox.find_element_by_name('pass')
email.send_keys('seu_email')
password.send_keys('sua_senha')
firefox.find_element_by_id('u_0_n').send_keys(Keys.ENTER)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment