Local Python Server Installation

Chris Gonnerman chris.gonnerman at newcenturycomputers.net
Sat Sep 21 12:31:50 EDT 2002


----- Original Message ----- 
From: "Kenneth Gomez" <kennethg at pd.jaring.my>


> I tried your method. But instead of getting a cgi listing of 
> my environmental listings, all I saw on my browser was the 
> two input lines ..i.e. import cgi and cgi.test()

Your cgi is being displayed rather than executed.  The 
configuration options for Apache are so complex, that entire 
books have been written about configuring it... and Gerhard's
suggestion only works on Windows platforms (AFAIK).  You didn't 
name your platform, did you?  Or did I just miss it?

You need to verify that Apache 1) recognizes .py files as CGI 
scripts, and 2) allows you to run a CGI in the folder you're 
putting it in.  You probably should put your script in the
cgi-bin directory to start with.  If you are on a Unix/Linux
system, you need to make sure that the script is marked 
executable.

Really, I think you need to spend some time with the Apache 
docs.  It isn't a Python problem per se.

Chris Gonnerman -- chris.gonnerman at newcenturycomputers.net
http://newcenturycomputers.net





More information about the Python-list mailing list