Mod_python and SMTP server

Doug Holton insert at spam.here
Sun Jul 18 21:00:05 CEST 2004


Nancy wrote:
> Hi,
>   Is there any one knows, if I want to use mod_python to handle my
> html form, I must have a SMTP server on my PC(winxp pro)?
>   Where can I get a free SMTP server?
> 
>   I cann't follow mod_python's manual example
> (http://www.svencoop.com/manual/mod/mod_python/tut-pub.html), why ...

Right, the example assumes you are running on Linux or Mac OS X, which
run an SMTP server (like sendmail) by default.

You could search for an STMP server for Windows (like blat or xmail), 
but that isn't necessary.

You can change the SMTP_SERVER line in your program to use the same STMP 
server that your email uses.  Also, change WEBMASTER to your own email 
address.
If that server requires you to login before allowing you to send email, 
add this line to your script after "conn = smtplib.SMTP(SMTP_SERVER)":
conn.login(username, password)



More information about the Python-list mailing list