[Tutor] need help with sending email

shawn bright nephish at gmail.com
Sat Jan 6 00:25:19 CET 2007


this is really cool. working too,
we have one provider now that it does not work with, but i think its them
this time.
thanks for your help on this

shawn

On 1/5/07, Christopher Arndt <chris.arndt at web.de> wrote:
>
> shawn bright schrieb:
> > lo there all.
> >
> > i am in a tight spot because i need to send an email that it mime
> > encoded plain-text ( not html or anything )
> >
> > anyone know of a good tutorial or recipe out there ?
>
> Simplified example from http://www.python.org/doc/current/lib/node162.html
> :
>
> # Import the email modules we'll need
> from email.MIMEText import MIMEText
>
> # Create a text/plain message
> msg = MIMEText("Hello World!")
>
> # me == the sender's email address
> # you == the recipient's email address
> msg['Subject'] = 'This is a test message'
> msg['From'] = 'me'
> msg['To'] = 'you'
>
> # Print string repreentation of message
> print msg.as_string()
>
>
> Outputs:
>
> Content-Type: text/plain; charset="us-ascii"
> MIME-Version: 1.0
> Content-Transfer-Encoding: 7bit
> Subject: This is a test message
> From: me
> To: you
>
> Hello World!
> _______________________________________________
> Tutor maillist  -  Tutor at python.org
> http://mail.python.org/mailman/listinfo/tutor
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.python.org/pipermail/tutor/attachments/20070105/9bc37538/attachment.htm 


More information about the Tutor mailing list