sendmail smtplib.SMTP('localhost') Where is the email?
inq1ltd
inq1ltd at inqvista.com
Thu May 30 15:48:20 EDT 2013
python help,
I've tried this code which I got from:
http://www.tutorialspoint.com/python/python_sending_email.htm
I build this file and run it
---//---
#!/usr/bin/python
import smtplib
sender = "inq1ltd at inqvista.com"
receivers = ["webmaster at inqvista.com"]
message = """From: jol
To: webmaster
Subject: SMTP e-mail test
This is a test e-mail message.
"""
try:
smtpObj = smtplib.SMTP('localhost')
smtpObj.sendmail(sender, receivers, message)
print "Successfully sent email"
except SMTPException:
print "Error: unable to send email"
--//--
After running the the file and I get
"Successfully sent email"
My question is why doesn't webmaster get an email?
jol
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-list/attachments/20130530/285ce597/attachment.html>
More information about the Python-list
mailing list