1,前半部分借鉴这
https://blog.csdn.net/weixin_43595001/article/details/84204651
2. 我试一下用pycharm写代码自动登录CSDN
(1)先输入以下代码:
# coding=utf-8
from selenium import webdriver
import time
browser = webdriver.Chrome(executable_path='C:\Program Files (x86)\Google\Chrome\Application\chromedriver.exe')
browser.get('https://passport.csdn.net/passport_fe/login.html')
(2)打开网址 https://passport.csdn.net/passport_fe/login.html
(3)按 F12
找到“账号登录”的classname 写入代码,命令点击