Python_it python_it at
Tue Oct 11 09:42:37 CEST 2005

Today I was busy to install mod_python.

I have put the line

LoadModule python_module libexec/

into the httpd.conf file.
It Works!
Apache load mod_python /3.2.2.b Python2.4

But my problem is where I have to place te following code in de

    <Directory C:\Program Files\Apache Group\Apache2\htdocs\project\>
        AddHandler mod_python .py
        PythonHandler mptest
        PythonDebug On

Because al the tutorials write this. But where?

If I try to put the code some where,
apache give the following message by testing the configure:
Multiple <Directory> arguments not (yet) supported
But what i have to change or replace.

I test with the next file:

C:\Program Files\Apache Group\Apache2\htdocs\project\

from mod_python import apache

def handler(req):
   req.content_type = 'text/plain'
   return apache.OK

Is this code enough for testing?

More information about the Python-list mailing list