Apache windows server : python module

Erika Skoe eeskoe at yahoo.com
Sat Feb 16 18:38:18 EST 2002


it looks lke mod_python itself isn't installed.  you'll get better answers,
however, from the mod_python mailing list.


"Aliocha" <aliocha_z at caramail.com> wrote in message
news:a4m865$80v$1 at wanadoo.fr...
> Hi,
>
> I have followed all indications to install python module for apache on the
> web page :
> (http://www.modpython.org/live/mod_python-2.7.6/doc-html/app-wininst.html)
> but when I start the server, this are the error lines :
>
> "Syntax error on line 631 of c:/program files/apache
> group/apache/conf/httpd:
> Invalid command 'PythonHandler', perhaps mis-spelled or defined by a
module
> included in the server configuration
> Note the errors or messages above, and press the <ESC> key to exit.
20..."
>
> Somebody have already met this problem ?
>
> Precisions :
> --------------------------------------------------------------------------
--
>
> The line which doesn't work in httpd.conf :
> It's the line "PythonHandler mptest" which redirect to "mptest.py".
> This file is in my "C:/Program Files/Apache Group/Apache/htdocs/python" .
> this file must print "Hello World"  in my browser.
>
>    <Directory "C:/Program Files/Apache Group/Apache/htdocs/python">
>     AddHandler python-program .py
>     PythonHandler mptest
>     PythonDebug on
>    </Directory>
>
> --------------------------------------------------------------------------
--
>
> Content of mptest.py :
>
> from mod_python import apache
>
> def handler(req):
>    req.content_type = "text/plain"
>    req.send_http_header()
>    req.write("Hello World!")
>    return apache.OK
>
> --------------------------------------------------------------------------
--
>
> Configuration :
>
> I have installed :
> - Apache : apache_1.3.22-win32-x86.exe
> - the python module files : mod_python-2.7.6.tgz
> - The dll of python module :  python2.2-apache1.3.22
> - Python executable : Python-2.2.exe
>
>
>





More information about the Python-list mailing list