Python / CGI / E-mail problem
ben at co.and.co
ben at co.and.co
Tue May 16 06:00:51 EDT 2000
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