mail sending -- smtplib
kurianmthayil at gmail.com
Tue Sep 7 06:27:28 CEST 2010
I am a newbie in python. Just 2-3 days old wanting to learn this amazing
programming language. I was trying to send mails using smtplib module, so
did some google and found a code snippet. The mail gets sent, but doesn't
come in the right format when a for-loop is introduced (Not MIME standard?).
Without the for-loop the script works fine. Can anyone advice?
for i in range(1,5):
print "I is ",i
fromaddr='kurianmthayil at gmail.com'
toaddr='kurianmthayil at gmail.com'
mssg="""From: Kurian Thayil <kurianmthayil at gmail.com>
To: Kurian Thayil <kurianmthayil at gmail.com>
Subject: 12345 -- Reloaded :)
<b>Hey dude.. how are you????</b>
print "message is ",mssg
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Python-list