I'm trying to create a python script that helps me to login into my gmail account when run. I took a quick look at the gmail login page and it was like 2000 lines. Most of it was css and some script. What i want is the script to contain my login details and send them when ran.
1 Answer
import smtplib
# Set connection. This has to be using TLS
connection = smtplib.SMTP('smtp.gmail.com', 587)
# Say hello, god knows why
connection.ehlo()
# Start TLS session
connection.starttls()
# Try to login with email/pwd
connection.login('[email protected]', 'mypwd')
# Close it
connection.close()
actionandmethodattributes and fill theinputfields manually, should be doable I guess...