##
## darkcoding webmail
##
## by Graham King
##
## feedback@darkcoding.net
##
## This is licenced under the GNU GPL. See COPYING file for details

darkcoding webmail is a simple web based e-mail client. It supports POP3, SMTP, and a variety of MIME attachments. It is written entirely in Python. I hope you find it usefull.

#
# Setup:
#

1) Find out if your ISP has Python installed, and where it is. 
Change the first line of each .py file to point to python. For a typical install if your ISP is running Linux it should work as is.

2) Ensure your ISP has as least Python 2+.
To find out upload this short script:
---
#!/usr/bin/python

import sys

print "Content-type: text/plain"
print 
print sys.version
---
and execute it as a cgi.
If the first number is not two ask your ISP to upgrade.

3) Edit mailUtils.py
Fill in things like your username, your pop3 server name, etc. The comments in there should help.

4) Create and upload 'mail-password.txt' (or whatever you chose to call it). 
Remember to put this somewhere were people can't browse to it but the mail server can read it.

5) Create on the webserver any necessary directories (such as 'tmp', 'attachments', etc).

6) Create a secure area to put the scripts.
As your login details are stored on the server, you just need to hit a url to browse your mail. Which means anyone can read your mail. For that reason you should create a 'private' directory and secure it using .htaccess and .htpasswd (see Apache docs for more info) or whatever mechanism your webserver provides.

7) Upload all the .py files to a cgi-bin directory on your server, somewhere under the secured directory created in step 6.

8) Browse to http://yoursever/yourPrivateDir/mailList.py to start !

#
# Troubleshooting
#

If you get an error from the webserver, or only the menu bar appears, check the error_log of your webserver. Then flex your Python muscles and dive in. It's probably a simple configuration mistake.

If you are still stuck write to me at the address at the top of this file and I'll try and help.

#
# Contribute
#

Bug reports, code submissions, correspondence, etc, all welcome to the address at the top of this file.

