Install Python on Apache

Cameron Laird claird at starbase.neosoft.com
Fri Mar 23 23:36:13 CET 2001


In article <99fph5$a2n$1 at rex.ip-plus.net>, Sharp <s.sharp at fh-aargau.ch> wrote:
>Hi Everybody
>
>I sucked down Python from python.org and started to install the program
>on a win2000 apache system. that has worked perfectly. but then I tried
>to set up the apache httpd.conf file with the following options
>
>AddType application/x-httpd-py .py
>Action application/x-httpd-py /cgi-bin/Python/python.exe
>
>(cgi.bin is set to the right place because php and perl do work)
>
>But then it did not work. I hava also tried several variations but always
>with the same comands.
>The Error Message in the Apache error.log was
>
>[Fri Mar 23 15:54:50 2001] [error] [client xxx.xxx.xxx.xxx] Premature end of
>script headers: c:/web/cgi-bin/python/python.exe
>
>the script is looking like this
>
>#!c:/web/cgi-bin/Python/python.exe
>print "<html>";
			.
			.
			.
I confess I've never used Apache on Win*.  I'm
willing to bet, though, that starting this with
  #!c:/web/cgi-bin/Python/python.exe
  print "Content-type: text/html\n"
  print "<html>";
     ...
instead will get you closer to what you want.
-- 

Cameron Laird <claird at NeoSoft.com>
Business:  http://www.Phaseit.net
Personal:  http://starbase.neosoft.com/~claird/home.html



More information about the Python-list mailing list