MIME attachments and SMTP

Martin Bertolino com.talx at mxb
Tue Sep 12 12:31:12 EDT 2000


You probaly need to check RFC 1521 -> MIME Part One
(http://www.ietf.org/rfc). I recently wrote some code (C++ though) based on
the information contained in this document. It also helped to send myself
emails with attachments, and then examine the 'raw' documents with a text
editor rather than viewing them within the email client. I would assume that
the email client you use will let you browse the messages you receive
without interpretation.

I hope this helps

Martin

<rick_at_brickroad at my-deja.com> wrote in message
news:8pjstm$oqh$1 at nnrp1.deja.com...
> I'm trying to set up a command line utility in
> python.. and I've set up the SMTP to specs but
> when I send a message doing:
> server = smtplib.SMTP('myserver')
> server.set_debuglevel(1)
> fromaddr = 'rickr at brickroad.net'
> toaddrs = 'rickr at brickroad.net'
> msg = 'blah blah blah blah'
> server.sendmail(fromaddr, toaddrs, msg)
> server.quit()
>
> however, it arrives it arrives with no to: and no
> subject.
>
> I was also wondering if someone could point me to
> more information on using mime types to add
> attachments. I've gone through the docs.. but
> can't find much information on this.
>
> thanks
>
> Rick
>
>
> Sent via Deja.com http://www.deja.com/
> Before you buy.





More information about the Python-list mailing list