Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit 5488454

Browse files
Added Insta Automation
1 parent 61bb35d commit 5488454

File tree

1 file changed

+17
-0
lines changed

1 file changed

+17
-0
lines changed

‎Insta-Autologin/main.py‎

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
from selenium import webdriver
2+
from webdriver_manager.chrome import ChromeDriverManager
3+
from selenium.webdriver.common.keys import Keys
4+
from getpass import getpass
5+
import time
6+
chrome = webdriver.Chrome(ChromeDriverManager().install())
7+
chrome.get("https://instagram.com")
8+
time.sleep(4)
9+
username = chrome.find_element_by_xpath('//*[@id="loginForm"]/div/div[1]/div/label/input')
10+
a = input("Enter username: ")
11+
username.send_keys(a)
12+
password = chrome.find_element_by_xpath('//*[@id="loginForm"]/div/div[2]/div/label/input')
13+
b = getpass()
14+
password.send_keys(b)
15+
#time.sleep(2)
16+
login_btn = chrome.find_element_by_xpath('//*[@id="loginForm"]/div/div[3]/button/div')
17+
login_btn.click()

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /