Python / CGI / E-mail problem

Sreekant Kodela sreekant at uklinux.net
Tue May 16 13:00:43 EDT 2000


Hi there

I tried using the MimeWriter but failed. Do you have any simple exampe by
any chance.

thanks
sreekant


ben at co.and.co wrote:

> Sreekant Kodela <sreekant at uklinux.net> wrote:
> > Hi there
> >
> > I am trying to send automated emails to the people who joined the
> > mailing list. I am using the smtplib and sending the mail but my users
> > came back to me that they can see the code. I tried to mail it to my
> > self and hotmail was ok but pop/kmail was showing the code. I am using
> > the following method. Is there anything stupid I'm doing!!
> >
> > hdr='From: xxxxx'+smtplib.CRLF+'SUBJECT: xxxxxx'+smtplib.CRLF
> > hdr2='<html><head><title>StokZilla</title></head><body
>
> For anything else than a plain text message, you need to pack the body
> in MIME-headers, telling the MUA how to render the content.
> In your case, you need to tell the MUA its a HTML-message.
> The headers should contain
> Content-Type: text/html; charset=iso-8859-1
>
> Take a look at the MimeWriter-module.
>
> Greetings,
> --
> ben . de . rydt at pandora . be ------------------ your comments
> http://users.pandora.be/bdr/ ------- inl. IPv6, Linux en Pandora




More information about the Python-list mailing list